Class MockKillByQueryMatchConsumer
- java.lang.Object
-
- com.funnelback.plugin.index.consumers.mock.MockKillByQueryMatchConsumer
-
- All Implemented Interfaces:
KillByQueryMatchConsumer
public class MockKillByQueryMatchConsumer extends Object implements KillByQueryMatchConsumer
A mockKillByQueryMatchConsumer
that may be used when testingIndexingConfigProvider.killByQueryMatch(IndexConfigProviderContext, KillByQueryMatchConsumer)
. Example:MockIndexConfigProviderContext mockContext = new MockIndexConfigProviderContext(); MockKillByQueryMatchConsumer mockConsumer = new MockKillByQueryMatchConsumer(); ExamplePluginIndexingConfigProvider underTest = new ExamplePluginIndexingConfigProvider(); underTest.killByExactMatch(mockContext, mockConsumer); Assert.assertTrue("Assert something useful.", mockConsumer.getInvocations().size() >= 0);
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
MockKillByQueryMatchConsumer.MockKillByQueryMatchInvocation
Holds the values thatkillByQueryMatch(String)
was called with.
-
Field Summary
Fields Modifier and Type Field Description private List<MockKillByQueryMatchConsumer.MockKillByQueryMatchInvocation>
invocations
Hold the values of all invocations ofkillByQueryMatch(String)
.
-
Constructor Summary
Constructors Constructor Description MockKillByQueryMatchConsumer()
-
-
-
Field Detail
-
invocations
private final List<MockKillByQueryMatchConsumer.MockKillByQueryMatchInvocation> invocations
Hold the values of all invocations ofkillByQueryMatch(String)
.
-
-
Method Detail
-
killByQueryMatch
public void killByQueryMatch(String urlToKillByQueryMatch) throws IllegalArgumentException
- Specified by:
killByQueryMatch
in interfaceKillByQueryMatchConsumer
- Throws:
IllegalArgumentException
-
-