Skip to content

Commit 030486f

Browse files
committed
test(index): remove deprecated warning test
1 parent c0e47fa commit 030486f

File tree

1 file changed

+0
-19
lines changed

1 file changed

+0
-19
lines changed

packages/js/src/index.test.ts

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -395,25 +395,6 @@ describe('@storyblok/js', () => {
395395
window.location = originalLocation;
396396
});
397397

398-
it('should warn when not in editor mode', () => {
399-
const consoleSpy = vi.spyOn(console, 'warn');
400-
const callback = vi.fn();
401-
402-
// Ensure we're not in an iframe
403-
Object.defineProperty(window, 'parent', {
404-
value: { location: window.location },
405-
writable: true,
406-
});
407-
408-
loadBridge('https://app.storyblok.com/f/storyblok-v2-latest.js');
409-
window.storyblokRegisterEvent(callback);
410-
411-
expect(consoleSpy).toHaveBeenCalledWith(
412-
'You are not in Draft Mode or in the Visual Editor.',
413-
);
414-
expect(callback).not.toHaveBeenCalled();
415-
});
416-
417398
it('should execute callbacks in order of registration', async () => {
418399
const executionOrder: number[] = [];
419400
const callback1 = vi.fn(() => executionOrder.push(1));

0 commit comments

Comments
 (0)