chore: add resize observer mock

This commit is contained in:
Pavel Mineev
2022-12-05 12:03:36 -06:00
committed by Umputun
parent 050bce163a
commit 8d95baa70f
2 changed files with 12 additions and 0 deletions
@@ -0,0 +1,11 @@
global.ResizeObserver = class ResizeObserver {
observe() {
// do nothing
}
unobserve() {
// do nothing
}
disconnect() {
// do nothing
}
};
+1
View File
@@ -33,6 +33,7 @@ const config: Config = {
setupFilesAfterEnv: [
'<rootDir>/app/__mocks__/fetch.ts',
'<rootDir>/app/__mocks__/localstorage.ts',
'<rootDir>/app/__mocks__/resize-observer.ts',
'<rootDir>/app/__stubs__/remark-config.ts',
'<rootDir>/app/__stubs__/static-config.ts',
],