chore: improve typings in reactivity tests (#96)

This commit is contained in:
Carlos Rodrigues
2019-10-05 15:39:40 +01:00
committed by Evan You
parent 0fe8801782
commit 600ec5de42
6 changed files with 24 additions and 24 deletions

View File

@@ -19,7 +19,7 @@ describe('reactivity/reactive', () => {
})
test('Array', () => {
const original: any[] = [{ foo: 1 }]
const original = [{ foo: 1 }]
const observed = reactive(original)
expect(observed).not.toBe(original)
expect(isReactive(observed)).toBe(true)
@@ -88,7 +88,7 @@ describe('reactivity/reactive', () => {
})
test('setting a property with an unobserved value should wrap with reactive', () => {
const observed: any = reactive({})
const observed = reactive<{ foo?: object }>({})
const raw = {}
observed.foo = raw
expect(observed.foo).not.toBe(raw)