mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-05-29 16:46:16 +00:00
Created shortUrlVisits reducer test
This commit is contained in:
@@ -66,6 +66,7 @@ describe('shortUrlDetailReducer', () => {
|
||||
const { type: secondCallType } = secondCallArg;
|
||||
|
||||
expect(dispatchMock.callCount).toEqual(expectedDispatchCalls);
|
||||
expect(ShlinkApiClient.getShortUrl.callCount).toEqual(1);
|
||||
expect(firstCallType).toEqual(GET_SHORT_URL_DETAIL_START);
|
||||
expect(secondCallType).toEqual(GET_SHORT_URL_DETAIL_ERROR);
|
||||
});
|
||||
@@ -84,6 +85,7 @@ describe('shortUrlDetailReducer', () => {
|
||||
const { type: secondCallType, shortUrl } = secondCallArg;
|
||||
|
||||
expect(dispatchMock.callCount).toEqual(expectedDispatchCalls);
|
||||
expect(ShlinkApiClient.getShortUrl.callCount).toEqual(1);
|
||||
expect(firstCallType).toEqual(GET_SHORT_URL_DETAIL_START);
|
||||
expect(secondCallType).toEqual(GET_SHORT_URL_DETAIL);
|
||||
expect(shortUrl).toEqual(resolvedShortUrl);
|
||||
|
||||
Reference in New Issue
Block a user