mirror of
https://github.com/ershisan99/it-incubator-todolist-ts-17-live-2024-08-17.git
synced 2026-02-04 21:02:13 +00:00
chore: rename action creators to remove "AC"
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
import {
|
||||
appReducer,
|
||||
InitialStateType,
|
||||
setAppErrorAC,
|
||||
setAppStatusAC,
|
||||
setAppError,
|
||||
setAppStatus,
|
||||
} from './app-reducer'
|
||||
|
||||
let startState: InitialStateType
|
||||
@@ -16,11 +16,11 @@ beforeEach(() => {
|
||||
})
|
||||
|
||||
test('correct error message should be set', () => {
|
||||
const endState = appReducer(startState, setAppErrorAC('some error'))
|
||||
const endState = appReducer(startState, setAppError('some error'))
|
||||
expect(endState.error).toBe('some error')
|
||||
})
|
||||
|
||||
test('correct status should be set', () => {
|
||||
const endState = appReducer(startState, setAppStatusAC('loading'))
|
||||
const endState = appReducer(startState, setAppStatus('loading'))
|
||||
expect(endState.status).toBe('loading')
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user