X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/095e176632bbf81d28a239742a1ecce12404bd2d..06b6ba8fd1ee85ab6758261e4f782306cebeb0c1:/services/workbench2/src/views-components/auto-logout/auto-logout.test.tsx

diff --git a/services/workbench2/src/views-components/auto-logout/auto-logout.test.tsx b/services/workbench2/src/views-components/auto-logout/auto-logout.test.tsx
index c9b9e2b83f..28084ed1c1 100644
--- a/services/workbench2/src/views-components/auto-logout/auto-logout.test.tsx
+++ b/services/workbench2/src/views-components/auto-logout/auto-logout.test.tsx
@@ -14,15 +14,12 @@ describe('<AutoLogoutComponent />', () => {
     const sessionIdleTimeout = 300;
     const lastWarningDuration = 60;
     const eventListeners = {};
-    jest.useFakeTimers();
 
-    beforeAll(() => {
+    beforeEach(() => {
+        jest.useFakeTimers();
         window.addEventListener = jest.fn((event, cb) => {
             eventListeners[event] = cb;
         });
-    });
-
-    beforeEach(() => {
         props = {
             sessionIdleTimeout: sessionIdleTimeout,
             lastWarningDuration: lastWarningDuration,
