]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
test(apiWatch): better indicate array pre & new values are the same object (#7251)
authorYuchao <yuchao.sydneyuni@gmail.com>
Fri, 10 Nov 2023 06:37:46 +0000 (17:37 +1100)
committerGitHub <noreply@github.com>
Fri, 10 Nov 2023 06:37:46 +0000 (14:37 +0800)
packages/runtime-core/__tests__/apiWatch.spec.ts

index f24ce80b9dfba3546455b16917f5eeb35c715ba4..dcb1d6a5f28422ef434df70a5e5256d49fffdd22 100644 (file)
@@ -91,7 +91,7 @@ describe('api: watch', () => {
     array.push(1)
     await nextTick()
     expect(spy).toBeCalledTimes(1)
-    expect(spy).toBeCalledWith([1], expect.anything(), expect.anything())
+    expect(spy).toBeCalledWith([1], [1], expect.anything())
   })
 
   it('should not fire if watched getter result did not change', async () => {