mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-03-10 17:43:51 +00:00
Fixed typo
This commit is contained in:
@@ -1,24 +1,24 @@
|
||||
import reduce, {
|
||||
import reducer, {
|
||||
RESET_SHORT_URL_PARAMS,
|
||||
resetShortUrlParams,
|
||||
} from '../../../src/short-urls/reducers/shortUrlsListParams';
|
||||
import { LIST_SHORT_URLS } from '../../../src/short-urls/reducers/shortUrlsList';
|
||||
|
||||
describe('shortUrlsListParamsReducer', () => {
|
||||
describe('reducer', () => {
|
||||
describe('reducerr', () => {
|
||||
const defaultState = { page: '1' };
|
||||
|
||||
it('returns default value when action is unknown', () =>
|
||||
expect(reduce(defaultState, { type: 'unknown' })).toEqual(defaultState));
|
||||
expect(reducer(defaultState, { type: 'unknown' })).toEqual(defaultState));
|
||||
|
||||
it('returns params when action is LIST_SHORT_URLS', () =>
|
||||
expect(reduce(defaultState, { type: LIST_SHORT_URLS, params: { searchTerm: 'foo' } })).toEqual({
|
||||
expect(reducer(defaultState, { type: LIST_SHORT_URLS, params: { searchTerm: 'foo' } })).toEqual({
|
||||
...defaultState,
|
||||
searchTerm: 'foo',
|
||||
}));
|
||||
|
||||
it('returns default value when action is RESET_SHORT_URL_PARAMS', () =>
|
||||
expect(reduce(defaultState, { type: RESET_SHORT_URL_PARAMS })).toEqual(defaultState));
|
||||
expect(reducer(defaultState, { type: RESET_SHORT_URL_PARAMS })).toEqual(defaultState));
|
||||
});
|
||||
|
||||
describe('resetShortUrlParams', () => {
|
||||
|
||||
Reference in New Issue
Block a user