From 21a0f2294b51f6ce78134384d34f302fb2cb8614 Mon Sep 17 00:00:00 2001 From: Shin'ya Ueoka Date: Sat, 15 May 2021 18:03:43 +0900 Subject: Remove legacy find --- .../operators/impls/FindNextOperator.test.ts | 17 ----------------- .../impls/FindOperatorFactoryChain.test.ts | 21 --------------------- .../operators/impls/FindPrevOperator.test.ts | 17 ----------------- 3 files changed, 55 deletions(-) delete mode 100644 test/content/operators/impls/FindNextOperator.test.ts delete mode 100644 test/content/operators/impls/FindOperatorFactoryChain.test.ts delete mode 100644 test/content/operators/impls/FindPrevOperator.test.ts (limited to 'test/content/operators') diff --git a/test/content/operators/impls/FindNextOperator.test.ts b/test/content/operators/impls/FindNextOperator.test.ts deleted file mode 100644 index d93d45e..0000000 --- a/test/content/operators/impls/FindNextOperator.test.ts +++ /dev/null @@ -1,17 +0,0 @@ -import sinon from "sinon"; -import FindNextOperator from "../../../../src/content/operators/impls/FindNextOperator"; -import MockFindMasterClient from "../../mock/MockFindMasterClient"; - -describe("FindNextOperator", () => { - describe("#run", () => { - it("find next keyword", async () => { - const client = new MockFindMasterClient(); - const mock = sinon.mock(client).expects("findNext").exactly(3); - const sut = new FindNextOperator(client, 3); - - await sut.run(); - - mock.verify(); - }); - }); -}); diff --git a/test/content/operators/impls/FindOperatorFactoryChain.test.ts b/test/content/operators/impls/FindOperatorFactoryChain.test.ts deleted file mode 100644 index 6c599ae..0000000 --- a/test/content/operators/impls/FindOperatorFactoryChain.test.ts +++ /dev/null @@ -1,21 +0,0 @@ -import * as operations from "../../../../src/shared/operations"; -import { expect } from "chai"; -import FindOperatorFactoryChain from "../../../../src/content/operators/impls/FindOperatorFactoryChain"; -import MockFindMasterClient from "../../mock/MockFindMasterClient"; -import FindNextOperator from "../../../../src/content/operators/impls/FindNextOperator"; -import FindPrevOperator from "../../../../src/content/operators/impls/FindPrevOperator"; - -describe("FindOperatorFactoryChain", () => { - describe("#create", () => { - it("returns an operator", () => { - const sut = new FindOperatorFactoryChain(new MockFindMasterClient()); - expect(sut.create({ type: operations.FIND_NEXT }, 0)).to.be.instanceOf( - FindNextOperator - ); - expect(sut.create({ type: operations.FIND_PREV }, 0)).to.be.instanceOf( - FindPrevOperator - ); - expect(sut.create({ type: operations.SCROLL_TOP }, 0)).to.be.null; - }); - }); -}); diff --git a/test/content/operators/impls/FindPrevOperator.test.ts b/test/content/operators/impls/FindPrevOperator.test.ts deleted file mode 100644 index 1ebde8d..0000000 --- a/test/content/operators/impls/FindPrevOperator.test.ts +++ /dev/null @@ -1,17 +0,0 @@ -import sinon from "sinon"; -import FindPrevOperator from "../../../../src/content/operators/impls/FindPrevOperator"; -import MockFindMasterClient from "../../mock/MockFindMasterClient"; - -describe("FindPrevOperator", () => { - describe("#run", () => { - it("find previous keyword", async () => { - const client = new MockFindMasterClient(); - const mock = sinon.mock(client).expects("findPrev").exactly(3); - const sut = new FindPrevOperator(client, 3); - - await sut.run(); - - mock.verify(); - }); - }); -}); -- cgit v1.2.3