|
|
@@ -299,6 +299,17 @@ describe('patchProp', () => {
|
|
|
`Failed setting prop "someProp" on <div>: value foo is invalid.`,
|
|
|
).toHaveBeenWarnedLast()
|
|
|
})
|
|
|
+
|
|
|
+ test('checkbox with indeterminate', () => {
|
|
|
+ const el = document.createElement('input')
|
|
|
+ el.type = 'checkbox'
|
|
|
+ setProp(el, 'indeterminate', true)
|
|
|
+ expect(el.indeterminate).toBe(true)
|
|
|
+ setProp(el, 'indeterminate', false)
|
|
|
+ expect(el.indeterminate).toBe(false)
|
|
|
+ setProp(el, 'indeterminate', '')
|
|
|
+ expect(el.indeterminate).toBe(true)
|
|
|
+ })
|
|
|
})
|
|
|
|
|
|
describe('setDynamicProp', () => {
|