Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
Васильев Анатолий Андреевич01 committed Oct 25, 2023
1 parent 3cb4965 commit 91b887d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/utils/cloneDeep.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
import { beforeEach, describe, expect, it, vi } from 'vitest';
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
import { cloneDeep } from './cloneDeep';

describe('cloneDeep', () => {
beforeEach(() => {
global.structuredClone = vi.fn((val) => {
return JSON.parse(JSON.stringify(val));
});
});

afterEach(() => {
vi.restoreAllMocks();
});

Expand Down

0 comments on commit 91b887d

Please sign in to comment.