X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/f0ac109691369516a5adf9370838cb4eacf16a45..a2bf1ed3a15cf55e426c51ad8e6febd7ff2e3020:/src/store/auth/auth-reducer.test.ts diff --git a/src/store/auth/auth-reducer.test.ts b/src/store/auth/auth-reducer.test.ts index 8eeb7c3c63..1202bacb12 100644 --- a/src/store/auth/auth-reducer.test.ts +++ b/src/store/auth/auth-reducer.test.ts @@ -7,13 +7,19 @@ import { AuthAction, authActions } from "./auth-action"; import 'jest-localstorage-mock'; import { createServices } from "~/services/services"; +import { mockConfig } from '~/common/config'; +import { ApiActions } from "~/services/api/api-actions"; describe('auth-reducer', () => { let reducer: (state: AuthState | undefined, action: AuthAction) => any; + const actions: ApiActions = { + progressFn: (id: string, working: boolean) => {}, + errorFn: (id: string, message: string) => {} + }; beforeAll(() => { localStorage.clear(); - reducer = authReducer(createServices({ apiHost: "/arvados/v1", keepWebHost: "" })); + reducer = authReducer(createServices(mockConfig({}), actions)); }); it('should correctly initialise state', () => {