From: Daniel Kos Date: Tue, 18 Dec 2018 13:04:09 +0000 (+0100) Subject: Fix passing auth reducer tests X-Git-Tag: 1.4.0~71^2~15 X-Git-Url: https://git.arvados.org/arvados-workbench2.git/commitdiff_plain/77c99a3667bbbf09734bede8f154ef86a60d823b Fix passing auth reducer tests No issue # Arvados-DCO-1.1-Signed-off-by: Daniel Kos --- diff --git a/src/store/auth/auth-action.test.ts b/src/store/auth/auth-action.test.ts index d58c9159..e5775a49 100644 --- a/src/store/auth/auth-action.test.ts +++ b/src/store/auth/auth-action.test.ts @@ -56,6 +56,27 @@ describe('auth-actions', () => { expect(store.getState().auth).toEqual({ apiToken: "token", sshKeys: [], + sessions: [{ + "active": true, + "baseUrl": undefined, + "clusterId": undefined, + "email": "test@test.com", + "loggedIn": true, + "remoteHost": undefined, + "status": 2, + "token": "token", + "username": "John Doe" + }, { + "active": false, + "baseUrl": "", + "clusterId": "xc59", + "email": "", + "loggedIn": false, + "remoteHost": "xc59.api.arvados.com", + "status": 0, + "token": "", + "username": "" + }], user: { email: "test@test.com", firstName: "John", diff --git a/src/store/auth/auth-reducer.test.ts b/src/store/auth/auth-reducer.test.ts index eb7e0c0d..773f9f82 100644 --- a/src/store/auth/auth-reducer.test.ts +++ b/src/store/auth/auth-reducer.test.ts @@ -38,7 +38,8 @@ describe('auth-reducer', () => { expect(state).toEqual({ apiToken: "token", user, - sshKeys: [] + sshKeys: [], + sessions: [] }); }); @@ -49,7 +50,8 @@ describe('auth-reducer', () => { expect(state).toEqual({ apiToken: "token", user: undefined, - sshKeys: [] + sshKeys: [], + sessions: [] }); }); @@ -71,6 +73,7 @@ describe('auth-reducer', () => { expect(state).toEqual({ apiToken: undefined, sshKeys: [], + sessions: [], user: { email: "test@test.com", firstName: "John",