mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-23 20:18:00 +01:00
Silence any lint on window.location mock
This commit is contained in:
parent
df2e336a24
commit
089816845e
1 changed files with 2 additions and 0 deletions
|
@ -117,6 +117,7 @@ describe('Remote utilities', () => {
|
|||
// https://www.benmvp.com/blog/mocking-window-location-methods-jest-jsdom/
|
||||
let oldWindowLocation: Location;
|
||||
|
||||
/* eslint-disable @typescript-eslint/no-explicit-any */
|
||||
beforeAll(() => {
|
||||
oldWindowLocation = window.location;
|
||||
delete (window as any).location;
|
||||
|
@ -136,6 +137,7 @@ describe('Remote utilities', () => {
|
|||
beforeEach(() => {
|
||||
(window.location.reload as any).mockReset();
|
||||
});
|
||||
/* eslint-enable @typescript-eslint/no-explicit-any */
|
||||
|
||||
afterAll(() => {
|
||||
// restore window.location to the jsdom Location object
|
||||
|
|
Loading…
Reference in a new issue