Skip to content

Commit

Permalink
chore: test.todo
Browse files Browse the repository at this point in the history
  • Loading branch information
ubugeeei committed Jan 31, 2024
1 parent 7751465 commit c36257d
Showing 1 changed file with 36 additions and 33 deletions.
69 changes: 36 additions & 33 deletions packages/runtime-vapor/__tests__/componentProps.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ describe('component props (vapor)', () => {
// expect(props.qux).toEqual(5) // TODO: attrs
})

test('stateful with setup', () => {
test.todo('stateful with setup', () => {
// TODO:
})

Expand Down Expand Up @@ -294,7 +294,7 @@ describe('component props (vapor)', () => {
// expect(defaultFn).toHaveBeenCalledTimes(1) // failed: caching is not supported (called 3 times)
})

test('using inject in default value factory', () => {
test.todo('using inject in default value factory', () => {
// TODO: impl inject
})

Expand Down Expand Up @@ -356,24 +356,24 @@ describe('component props (vapor)', () => {
// expect(host.innerHTML).toBe('<div id="b">2</div>') // TODO: Fallthrough Attributes
})

test('validator', () => {
test.todo('validator', () => {
// TODO: impl validator
})

test('warn props mutation', () => {
test.todo('warn props mutation', () => {
// TODO: impl warn
})

test('warn absent required props', () => {
test.todo('warn absent required props', () => {
// TODO: impl warn
})

test('warn on type mismatch', () => {
test.todo('warn on type mismatch', () => {
// TODO: impl warn
})

// #3495
test('should not warn required props using kebab-case', async () => {
test.todo('should not warn required props using kebab-case', async () => {
// TODO: impl warn
})

Expand Down Expand Up @@ -411,33 +411,36 @@ describe('component props (vapor)', () => {
})

// #3288
test('declared prop key should be present even if not passed', async () => {
// let initialKeys: string[] = []
// const changeSpy = vi.fn()
// const passFoo = ref(false)
// const Comp = {
// props: ['foo'],
// setup() {
// const instance = getCurrentInstance()!
// initialKeys = Object.keys(instance.props)
// watchEffect(changeSpy)
// return {}
// },
// render() {
// return {}
// },
// }
// const Parent = createIf(
// () => passFoo.value,
// () => {
// return render(Comp , { foo: 1 }, host) // TODO: createComponent fn
// },
// )
// // expect(changeSpy).toHaveBeenCalledTimes(1)
})
test.todo(
'declared prop key should be present even if not passed',
async () => {
// let initialKeys: string[] = []
// const changeSpy = vi.fn()
// const passFoo = ref(false)
// const Comp = {
// props: ['foo'],
// setup() {
// const instance = getCurrentInstance()!
// initialKeys = Object.keys(instance.props)
// watchEffect(changeSpy)
// return {}
// },
// render() {
// return {}
// },
// }
// const Parent = createIf(
// () => passFoo.value,
// () => {
// return render(Comp , { foo: 1 }, host) // TODO: createComponent fn
// },
// )
// // expect(changeSpy).toHaveBeenCalledTimes(1)
},
)

// #3371
test(`avoid double-setting props when casting`, async () => {
test.todo(`avoid double-setting props when casting`, async () => {
// TODO: proide, slots
})

Expand All @@ -459,7 +462,7 @@ describe('component props (vapor)', () => {
})

// #5016
test('handling attr with undefined value', () => {
test.todo('handling attr with undefined value', () => {
// TODO: attrs
})

Expand Down

0 comments on commit c36257d

Please sign in to comment.