Skip to content

Commit

Permalink
chore: format
Browse files Browse the repository at this point in the history
  • Loading branch information
johnsoncodehk committed Apr 11, 2023
1 parent 1437440 commit 31d443b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 8 deletions.
16 changes: 10 additions & 6 deletions test-dts/shallowMount.d-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,11 @@ const AppWithDefine = defineComponent({

// accept props
// vm is properly typed
expectType<string>(shallowMount(AppWithDefine, {
props: { a: 'Hello', b: 2 }
}).vm.a)
expectType<string>(
shallowMount(AppWithDefine, {
props: { a: 'Hello', b: 2 }
}).vm.a
)

// allow extra props, like using `h()`
shallowMount(AppWithDefine, {
Expand Down Expand Up @@ -69,9 +71,11 @@ const AppWithArrayProps = {

// accept props
// vm is properly typed
expectType<string>(shallowMount(AppWithArrayProps, {
props: { a: 'Hello' }
}).vm.a)
expectType<string>(
shallowMount(AppWithArrayProps, {
props: { a: 'Hello' }
}).vm.a
)

// can receive extra props
// as they are declared as `string[]`
Expand Down
4 changes: 2 additions & 2 deletions tests/setData.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -190,13 +190,13 @@ describe('setData', () => {

it('should keep Date object on setData', async () => {
const wrapper = mount(
defineComponent({
{
template: '<div/>',
props: { modelValue: Date },
data() {
return { value: this.modelValue }
}
}),
},
{
props: {
modelValue: new Date('2022-08-10T12:15:54Z')
Expand Down

0 comments on commit 31d443b

Please sign in to comment.