Skip to content

Commit

Permalink
Merge pull request #2226 from topmonroe9/patch-1
Browse files Browse the repository at this point in the history
Updated jest function
  • Loading branch information
kamilmysliwiec committed Feb 25, 2022
2 parents 05f8d9a + a41a5e9 commit 714cdd3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion content/fundamentals/unit-testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ describe('CatsController', () => {
})
.useMocker((token) => {
if (token === CatsService) {
return { findAll: jest.fn().mockResolveValue(results) };
return { findAll: jest.fn().mockResolvedValue(results) };
}
if (typeof token === 'function') {
const mockMetadata = moduleMocker.getMetadata(token) as MockFunctionMetadata<any, any>;
Expand Down

0 comments on commit 714cdd3

Please sign in to comment.