mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-03 02:30:36 +08:00
6cbf5b2a92
Co-authored-by: AyushAgrawal-A2 <ayushagl06@gmail.com>
19 lines
339 B
TypeScript
19 lines
339 B
TypeScript
import { vi } from 'vitest';
|
|
|
|
vi.mock('lottie-web', () => ({
|
|
default: {},
|
|
}));
|
|
|
|
vi.mock('@blocksuite/presets', () => ({
|
|
EditorContainer: vi.fn(),
|
|
}));
|
|
|
|
if (typeof window !== 'undefined' && HTMLCanvasElement) {
|
|
// @ts-expect-error
|
|
HTMLCanvasElement.prototype.getContext = () => {
|
|
return {
|
|
fillRect: vi.fn(),
|
|
};
|
|
};
|
|
}
|