diff options
Diffstat (limited to 'test/background/operators/impls/ReopenTabOperator.test.ts')
-rw-r--r-- | test/background/operators/impls/ReopenTabOperator.test.ts | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/background/operators/impls/ReopenTabOperator.test.ts b/test/background/operators/impls/ReopenTabOperator.test.ts index 43b1575..5581f9a 100644 --- a/test/background/operators/impls/ReopenTabOperator.test.ts +++ b/test/background/operators/impls/ReopenTabOperator.test.ts @@ -1,4 +1,3 @@ -import sinon from "sinon"; import ReopenTabOperator from "../../../../src/background/operators/impls/ReopenTabOperator"; import MockTabPresenter from "../../mock/MockTabPresenter"; @@ -6,12 +5,14 @@ describe("ReopenTabOperator", () => { describe("#run", () => { it("reopens closed tabs", async () => { const tabPresenter = new MockTabPresenter(); - const mock = sinon.mock(tabPresenter).expects("reopen"); + const reopenSpy = jest + .spyOn(tabPresenter, "reopen") + .mockReturnValue(Promise.resolve()); const sut = new ReopenTabOperator(tabPresenter); await sut.run(); - mock.verify(); + expect(reopenSpy).toBeCalled(); }); }); }); |