test: effect.onStop
This commit is contained in:
parent
a0bc525fee
commit
cb3866890f
@ -624,6 +624,15 @@ describe('reactivity/effect', () => {
|
|||||||
expect(dummy).toBe(3)
|
expect(dummy).toBe(3)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
it('events: onStop', () => {
|
||||||
|
const runner = effect(() => {}, {
|
||||||
|
onStop: jest.fn()
|
||||||
|
})
|
||||||
|
|
||||||
|
stop(runner)
|
||||||
|
expect(runner.onStop).toHaveBeenCalled()
|
||||||
|
})
|
||||||
|
|
||||||
it('markNonReactive', () => {
|
it('markNonReactive', () => {
|
||||||
const obj = reactive({
|
const obj = reactive({
|
||||||
foo: markNonReactive({
|
foo: markNonReactive({
|
||||||
|
Loading…
Reference in New Issue
Block a user