forked from vuetifyjs/vuetify
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
62 changed files
with
2,977 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { test } from '~util/testing' | ||
import VBreadcrumbsItem from '~components/breadcrumbs/VBreadcrumbsItem' | ||
|
||
test('VBreadcrumbsItem.js', ({ mount }) => { | ||
it('should render component and match snapshot', () => { | ||
const wrapper = mount(VBreadcrumbsItem) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with custom activeClass and match snapshot', () => { | ||
const wrapper = mount(VBreadcrumbsItem, { | ||
propsData: { | ||
activeClass: 'breadcrumbs-item--active' | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
}) |
23 changes: 23 additions & 0 deletions
23
src/components/breadcrumbs/__snapshots__/VBreadcrumbsItem.spec.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`VBreadcrumbsItem.js should render component and match snapshot 1`] = ` | ||
<li> | ||
<a href="javascript:;" | ||
class="breadcrumbs__item" | ||
> | ||
</a> | ||
</li> | ||
`; | ||
|
||
exports[`VBreadcrumbsItem.js should render component with custom activeClass and match snapshot 1`] = ` | ||
<li> | ||
<a href="javascript:;" | ||
class="breadcrumbs__item" | ||
> | ||
</a> | ||
</li> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import VSpeedDial from '~components/buttons/VSpeedDial' | ||
import clickOutside from '~directives/click-outside' | ||
import { test } from '~util/testing' | ||
|
||
VSpeedDial.directives = { | ||
clickOutside | ||
} | ||
|
||
test('VSpeedDial.js', ({ mount }) => { | ||
it('should render component and match snapshot', () => { | ||
const wrapper = mount(VSpeedDial) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with custom transition and match snapshot', () => { | ||
const wrapper = mount(VSpeedDial, { | ||
propsData: { | ||
transition: 'dialog-transition' | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with custom direction and match snapshot', () => { | ||
const wrapper = mount(VSpeedDial, { | ||
propsData: { | ||
direction: 'right' | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
src/components/buttons/__snapshots__/VSpeedDial.spec.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`VSpeedDial.js should render component and match snapshot 1`] = ` | ||
<div class="speed-dial speed-dial--direction-top"> | ||
<div class="speed-dial__list"> | ||
</div> | ||
</div> | ||
`; | ||
|
||
exports[`VSpeedDial.js should render component with custom direction and match snapshot 1`] = ` | ||
<div class="speed-dial speed-dial--direction-right"> | ||
<div class="speed-dial__list"> | ||
</div> | ||
</div> | ||
`; | ||
|
||
exports[`VSpeedDial.js should render component with custom transition and match snapshot 1`] = ` | ||
<div class="speed-dial speed-dial--direction-top"> | ||
<div class="speed-dial__list"> | ||
</div> | ||
</div> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
import { mount } from 'avoriaz' | ||
import VCardMedia from '~components/cards/VCardMedia' | ||
|
||
describe('VCardMedia.js', () => { | ||
it('should render component and match snapshot', () => { | ||
const wrapper = mount(VCardMedia) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with contained background and match snapshot', () => { | ||
const wrapper = mount(VCardMedia, { | ||
propsData: { | ||
contain: true | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with custom height (string) and match snapshot', () => { | ||
const wrapper = mount(VCardMedia, { | ||
propsData: { | ||
height: '100px' | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with custom height (number) and match snapshot', () => { | ||
const wrapper = mount(VCardMedia, { | ||
propsData: { | ||
height: 100 | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render matching components with custom height', () => { | ||
const wrapper1 = mount(VCardMedia, { | ||
propsData: { | ||
height: '100px' | ||
} | ||
}) | ||
const wrapper2 = mount(VCardMedia, { | ||
propsData: { | ||
height: 100 | ||
} | ||
}) | ||
|
||
expect(wrapper1.html()).toEqual(wrapper2.html()) | ||
}) | ||
|
||
it('should render component with custom background image and match snapshot', () => { | ||
const wrapper = mount(VCardMedia, { | ||
propsData: { | ||
src: 'https://vuetifyjs.com/static/doc-images/cards/sunshine.jpg' | ||
} | ||
}) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { test } from '~util/testing' | ||
import VCardTitle from '~components/cards/VCardTitle' | ||
|
||
test('VCardTitle.js', ({ mount, functionalContext }) => { | ||
it('should render component and match snapshot', () => { | ||
const wrapper = mount(VCardTitle, functionalContext()) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
|
||
it('should render component with specific padding applied', () => { | ||
const wrapper = mount(VCardTitle, functionalContext({ | ||
props: { | ||
'primary-title': true | ||
} | ||
})) | ||
|
||
expect(wrapper.html()).toMatchSnapshot() | ||
}) | ||
}) |
Oops, something went wrong.