mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-03-14 03:23:49 +00:00
Fix incorrect types between testing library and vitest
This commit is contained in:
@@ -3,8 +3,6 @@ import type { HttpClient } from '../../../src/common/services/HttpClient';
|
||||
import { fetchServers } from '../../../src/servers/reducers/remoteServers';
|
||||
|
||||
describe('remoteServersReducer', () => {
|
||||
afterEach(vi.clearAllMocks);
|
||||
|
||||
describe('fetchServers', () => {
|
||||
const dispatch = vi.fn();
|
||||
const fetchJson = vi.fn();
|
||||
|
||||
@@ -19,8 +19,6 @@ describe('selectedServerReducer', () => {
|
||||
const selectServer = selectServerCreator(buildApiClient);
|
||||
const { reducer } = selectedServerReducerCreator(selectServer);
|
||||
|
||||
afterEach(vi.clearAllMocks);
|
||||
|
||||
describe('reducer', () => {
|
||||
it('returns default when action is RESET_SELECTED_SERVER', () =>
|
||||
expect(reducer(null, resetSelectedServer())).toBeNull());
|
||||
|
||||
@@ -15,8 +15,6 @@ describe('serversReducer', () => {
|
||||
def456: fromPartial({ id: 'def456' }),
|
||||
};
|
||||
|
||||
afterEach(vi.clearAllMocks);
|
||||
|
||||
describe('reducer', () => {
|
||||
it('returns edited server when action is EDIT_SERVER', () =>
|
||||
expect(serversReducer(list, editServer('abc123', { name: 'foo' }))).toEqual({
|
||||
|
||||
Reference in New Issue
Block a user