Skip to content

Commit

Permalink
test: rectify accidentally passing test
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Aug 8, 2024
1 parent 7d57432 commit 9b531d5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/runtime-dom/__tests__/patchProps.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,10 +181,11 @@ describe('runtime-dom: props patching', () => {
// anyway, here we just want to make sure Vue doesn't set non-string props
// to an empty string on nullish values - it should reset to its default
// value.
el.srcObject = null
const initialValue = el.srcObject
const fakeObject = {}
patchProp(el, 'srcObject', null, fakeObject)
expect(el.srcObject).not.toBe(fakeObject)
expect(el.srcObject).toBe(fakeObject)
patchProp(el, 'srcObject', null, null)
expect(el.srcObject).toBe(initialValue)
})
Expand Down

0 comments on commit 9b531d5

Please sign in to comment.