Search in sources :

Example 16 with PropertyParser

use of nl.knaw.huygens.timbuctoo.search.description.PropertyParser in project timbuctoo by HuygensING.

the class PropertyParserFactoryTest method getParserReturnsAStringListParserForList.

@Test
public void getParserReturnsAStringListParserForList() {
    PropertyParser parser = instance.getParser(List.class);
    assertThat(parser, is(instanceOf(StringListParser.class)));
}
Also used : PropertyParser(nl.knaw.huygens.timbuctoo.search.description.PropertyParser) Test(org.junit.Test)

Example 17 with PropertyParser

use of nl.knaw.huygens.timbuctoo.search.description.PropertyParser in project timbuctoo by HuygensING.

the class PropertyParserFactoryTest method getParserReturnsAStringPropertyParserForString.

@Test
public void getParserReturnsAStringPropertyParserForString() {
    PropertyParser parser = instance.getParser(String.class);
    assertThat(parser, is(instanceOf(StringPropertyParser.class)));
}
Also used : PropertyParser(nl.knaw.huygens.timbuctoo.search.description.PropertyParser) Test(org.junit.Test)

Example 18 with PropertyParser

use of nl.knaw.huygens.timbuctoo.search.description.PropertyParser in project timbuctoo by HuygensING.

the class PropertyParserFactoryTest method getParserReturnsADefaultLocationNamePropertyParserForLocationNames.

@Test
public void getParserReturnsADefaultLocationNamePropertyParserForLocationNames() {
    PropertyParser parser = instance.getParser(LocationNames.class);
    assertThat(parser, is(instanceOf(DefaultLocationNamePropertyParser.class)));
}
Also used : PropertyParser(nl.knaw.huygens.timbuctoo.search.description.PropertyParser) Test(org.junit.Test)

Aggregations

PropertyParser (nl.knaw.huygens.timbuctoo.search.description.PropertyParser)18 Test (org.junit.Test)18 Vertex (org.apache.tinkerpop.gremlin.structure.Vertex)4 ArgumentMatchers.anyString (org.mockito.ArgumentMatchers.anyString)4 FacetDescription (nl.knaw.huygens.timbuctoo.search.description.FacetDescription)3 PropertyDescriptor (nl.knaw.huygens.timbuctoo.search.description.PropertyDescriptor)3 Lists (com.google.common.collect.Lists)1 List (java.util.List)1 FacetValue (nl.knaw.huygens.timbuctoo.search.FacetValue)1 ListFacetValue (nl.knaw.huygens.timbuctoo.server.mediatypes.v2.search.ListFacetValue)1 SearchRequestV2_1 (nl.knaw.huygens.timbuctoo.server.mediatypes.v2.search.SearchRequestV2_1)1 TestGraphBuilder.newGraph (nl.knaw.huygens.timbuctoo.util.TestGraphBuilder.newGraph)1 VertexMatcher (nl.knaw.huygens.timbuctoo.util.VertexMatcher)1 GraphTraversal (org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversal)1 MatcherAssert.assertThat (org.hamcrest.MatcherAssert.assertThat)1 Matchers.contains (org.hamcrest.Matchers.contains)1 Matchers.containsInAnyOrder (org.hamcrest.Matchers.containsInAnyOrder)1 Before (org.junit.Before)1 BDDMockito.given (org.mockito.BDDMockito.given)1 Mockito.mock (org.mockito.Mockito.mock)1