Remove the resetAllMocks
call because restoreAllMocks
does the same thing, plus restores the mocked method's original functionality.
This commit is contained in:
parent
07930a396b
commit
65202b2aff
@ -11,7 +11,7 @@ import { IDatabaseTables } from "@spt-aki/models/spt/server/IDatabaseTables";
|
||||
import { DatabaseServer } from "@spt-aki/servers/DatabaseServer";
|
||||
import { ImporterUtil } from "@spt-aki/utils/ImporterUtil";
|
||||
|
||||
//mocks
|
||||
// Manually mock for the logger.
|
||||
import { WinstonLogger } from "@tests/__mocks__/WinstonLogger.mock";
|
||||
|
||||
export default <Environment> {
|
||||
@ -23,7 +23,7 @@ export default <Environment> {
|
||||
Container.registerTypes(container);
|
||||
Container.registerListTypes(container);
|
||||
|
||||
// Override registration to the container
|
||||
// Override registration to the container.
|
||||
container.register<WinstonLogger>("WinstonLogger", WinstonLogger, { lifecycle: Lifecycle.Singleton });
|
||||
|
||||
// Import the database.
|
||||
|
@ -25,8 +25,6 @@ describe("InsuranceController", () =>
|
||||
|
||||
afterEach(() =>
|
||||
{
|
||||
// Restore all mocks to their original implementations.
|
||||
vi.resetAllMocks();
|
||||
vi.restoreAllMocks();
|
||||
});
|
||||
|
||||
|
@ -16,8 +16,6 @@ describe("BotGenerator", () =>
|
||||
|
||||
afterEach(() =>
|
||||
{
|
||||
// Restore all mocks to their original implementations.
|
||||
vi.resetAllMocks();
|
||||
vi.restoreAllMocks();
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user