Exemplo n.º 1
0
 @Test
 public void testPresentTotalCount() throws URISyntaxException {
   Integer totalResults = new Integer(17);
   Resource thisMetaPage = createMetadata(true, totalResults);
   Literal tr = thisMetaPage.getModel().createTypedLiteral(totalResults);
   assertTrue(thisMetaPage.hasProperty(OpenSearch.totalResults, tr));
 }
Exemplo n.º 2
0
 @Test
 public void testAbsentTotalCount() throws URISyntaxException {
   Integer totalResults = null;
   Resource thisMetaPage = createMetadata(true, totalResults);
   assertFalse(thisMetaPage.hasProperty(OpenSearch.totalResults));
 }
Exemplo n.º 3
0
 @Test
 public void testItemEndpointHasCorrectType() throws URISyntaxException {
   Integer totalResults = null;
   Resource thisMetaPage = createMetadata(false, totalResults);
   assertTrue(thisMetaPage.hasProperty(RDF.type, API.ItemEndpoint));
 }