Skip to content

Commit 892b4a2

Browse files
RichDom2185sumomomomomo
authored andcommitted
Fix failing tests
1 parent 58b7981 commit 892b4a2

File tree

1 file changed

+4
-13
lines changed

1 file changed

+4
-13
lines changed

src/commons/sagas/__tests__/PersistenceSaga.ts

+4-13
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
import { Chapter, Variant } from 'js-slang/dist/types';
22
import { expectSaga } from 'redux-saga-test-plan';
3+
import { removeGoogleUserAndAccessToken } from 'src/commons/application/actions/SessionActions';
4+
import { playgroundUpdatePersistenceFile } from 'src/features/playground/PlaygroundActions';
35

46
import { PLAYGROUND_UPDATE_PERSISTENCE_FILE } from '../../../features/playground/PlaygroundTypes';
57
import { ExternalLibraryName } from '../../application/types/ExternalTypes';
6-
import { REMOVE_GOOGLE_USER_AND_ACCESS_TOKEN } from '../../application/types/SessionTypes';
78
import { actions } from '../../utils/ActionsHelper';
89
import {
910
CHANGE_EXTERNAL_LIBRARY,
@@ -47,18 +48,8 @@ beforeAll(() => {
4748

4849
test('LOGOUT_GOOGLE results in REMOVE_GOOGLE_USER_AND_ACCESS_TOKEN being dispatched', async () => {
4950
await expectSaga(PersistenceSaga)
50-
.put({
51-
type: PLAYGROUND_UPDATE_PERSISTENCE_FILE,
52-
payload: undefined,
53-
meta: undefined,
54-
error: undefined
55-
})
56-
.put({
57-
type: REMOVE_GOOGLE_USER_AND_ACCESS_TOKEN,
58-
payload: undefined,
59-
meta: undefined,
60-
error: undefined
61-
})
51+
.put(playgroundUpdatePersistenceFile(undefined))
52+
.put(removeGoogleUserAndAccessToken())
6253
.provide({
6354
call(effect, next) {
6455
return;

0 commit comments

Comments
 (0)