Skip to content

Commit 0178179

Browse files
committed
fix test
1 parent 94f8e33 commit 0178179

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

test/mocks/window.mock.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
const sinon = require("sinon"),
22
{ KuzzleEventEmitter } = require("../../src/core/KuzzleEventEmitter");
3-
const { getBrowserWindow } = require("../../src/utils/browser");
43

54
// A class to mock the global window object
65
class WindowMock extends KuzzleEventEmitter {
76
constructor() {
87
super();
98

10-
if (typeof getBrowserWindow() !== "undefined") {
9+
if (typeof window !== "undefined") {
1110
throw new Error(
1211
'Cannot mock add a global "window" object: already defined'
1312
);

0 commit comments

Comments
 (0)