Class MockQieByUrlConsumer
- java.lang.Object
-
- com.funnelback.plugin.index.consumers.mock.MockQieByUrlConsumer
-
- All Implemented Interfaces:
com.funnelback.plugin.index.consumers.QieByUrlConsumer
public class MockQieByUrlConsumer extends Object implements com.funnelback.plugin.index.consumers.QieByUrlConsumer
A mockQieByQueryConsumer
that may be used when testingIndexingConfigProvider.supplyQieByURL(IndexConfigProviderContext, QieByUrlConsumer)
. Example:MockIndexConfigProviderContext mockContext = new MockIndexConfigProviderContext(); MockQieByUrlConsumer mockConsumer = new MockQieByUrlConsumer(); ExamplePluginIndexingConfigProvider underTest = new ExamplePluginIndexingConfigProvider(); underTest.supplyQieByUrl(mockContext, mockConsumer); Assert.assertTrue("Assert something useful.", mockConsumer.getInvocations().size() >= 0);
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
MockQieByUrlConsumer.MockQieByQueryInvocation
Holds the values thatapplyQieWhenUrlMatches(double, String)
was called with.
-
Field Summary
Fields Modifier and Type Field Description private List<MockQieByUrlConsumer.MockQieByQueryInvocation>
invocations
Hold the values of all invocations ofapplyQieWhenUrlMatches(double, String)
.
-
Constructor Summary
Constructors Constructor Description MockQieByUrlConsumer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
applyQieWhenUrlMatches(double qieWeight, String url)
List<MockQieByUrlConsumer.MockQieByQueryInvocation>
getInvocations()
Hold the values of all invocations ofapplyQieWhenUrlMatches(double, String)
.
-
-
-
Field Detail
-
invocations
private final List<MockQieByUrlConsumer.MockQieByQueryInvocation> invocations
Hold the values of all invocations ofapplyQieWhenUrlMatches(double, String)
.
-
-
Method Detail
-
applyQieWhenUrlMatches
public void applyQieWhenUrlMatches(double qieWeight, String url) throws IllegalArgumentException
- Specified by:
applyQieWhenUrlMatches
in interfacecom.funnelback.plugin.index.consumers.QieByUrlConsumer
- Throws:
IllegalArgumentException
-
getInvocations
public List<MockQieByUrlConsumer.MockQieByQueryInvocation> getInvocations()
Hold the values of all invocations ofapplyQieWhenUrlMatches(double, String)
.
-
-