diff --git a/Changes b/Changes index a28f02c1..6cd8a9e6 100644 --- a/Changes +++ b/Changes @@ -2,7 +2,8 @@ - Added tests for the DNB scenario with custom max match and context size. (#745) -- Clean up named-vc. +- Cleaned up named-vc. +- Updated tests using the old match info web-services (#757) # version 0.73.1 diff --git a/src/test/java/de/ids_mannheim/korap/web/controller/MatchInfoControllerTest.java b/src/test/java/de/ids_mannheim/korap/web/controller/MatchInfoControllerTest.java index ec282c9d..21f2155e 100644 --- a/src/test/java/de/ids_mannheim/korap/web/controller/MatchInfoControllerTest.java +++ b/src/test/java/de/ids_mannheim/korap/web/controller/MatchInfoControllerTest.java @@ -23,7 +23,7 @@ public class MatchInfoControllerTest extends SpringJerseyTest { public void testGetMatchInfoPublicCorpus () throws KustvaktException { Response response = target().path(API_VERSION).path("corpus") .path("GOE").path("AGA").path("01784").path("p36-100") - .path("matchInfo").queryParam("foundry", "*").request().get(); + .queryParam("foundry", "*").request().get(); assertEquals(Status.OK.getStatusCode(), response.getStatus()); String entity = response.readEntity(String.class); JsonNode node = JsonUtils.readTree(entity); @@ -41,7 +41,7 @@ public void testGetMatchInfoPublicCorpus () throws KustvaktException { public void testGetMatchInfoNotAllowed () throws KustvaktException { Response response = target().path(API_VERSION).path("corpus") .path("GOE").path("AGI").path("04846").path("p36875-36876") - .path("matchInfo").queryParam("foundry", "*").request().get(); + .queryParam("foundry", "*").request().get(); assertEquals(Status.UNAUTHORIZED.getStatusCode(), response.getStatus()); String entity = response.readEntity(String.class); JsonNode node = JsonUtils.readTree(entity); @@ -58,7 +58,7 @@ public void testGetMatchInfoNotAllowed () throws KustvaktException { public void testGetMatchInfoWithAuthentication () throws KustvaktException { Response response = target().path(API_VERSION).path("corpus") .path("GOE").path("AGI").path("04846").path("p36875-36876") - .path("matchInfo").queryParam("foundry", "*").request() + .queryParam("foundry", "*").request() .header(Attributes.AUTHORIZATION, HttpAuthorizationHandler .createBasicAuthorizationHeaderValue("kustvakt", diff --git a/src/test/java/de/ids_mannheim/korap/web/lite/LiteSearchControllerTest.java b/src/test/java/de/ids_mannheim/korap/web/lite/LiteSearchControllerTest.java index 610646c0..6ce08e77 100644 --- a/src/test/java/de/ids_mannheim/korap/web/lite/LiteSearchControllerTest.java +++ b/src/test/java/de/ids_mannheim/korap/web/lite/LiteSearchControllerTest.java @@ -171,7 +171,7 @@ public void testParameterField () throws KustvaktException { @Test public void testMatchInfoGetWithoutSpans () throws KustvaktException { Response response = target().path(API_VERSION) - .path("corpus/GOE/AGA/01784/p36-46(5)37-45(2)38-42/matchInfo") + .path("corpus/GOE/AGA/01784/p36-46(5)37-45(2)38-42") .queryParam("foundry", "*").queryParam("spans", "false") .request().get(); assertEquals(Status.OK.getStatusCode(), response.getStatus()); @@ -187,7 +187,7 @@ public void testMatchInfoGetWithoutSpans () throws KustvaktException { @Test public void testMatchInfoGetWithoutHighlights () throws KustvaktException { Response response = target().path(API_VERSION) - .path("corpus/GOE/AGA/01784/p36-46(5)37-45(2)38-42/matchInfo") + .path("corpus/GOE/AGA/01784/p36-46(5)37-45(2)38-42") .queryParam("foundry", "xy").queryParam("spans", "false") .request().get(); assertEquals(Status.OK.getStatusCode(), response.getStatus()); @@ -223,7 +223,7 @@ public void testMatchInfoWithoutExtension () throws KustvaktException { @Test public void testMatchInfoGetWithHighlights () throws KustvaktException { Response response = target().path(API_VERSION) - .path("corpus/GOE/AGA/01784/p36-46(5)37-45(2)38-42/matchInfo") + .path("corpus/GOE/AGA/01784/p36-46(5)37-45(2)38-42") .queryParam("foundry", "xy").queryParam("spans", "false") .queryParam("hls", "true").request().get(); assertEquals(Status.OK.getStatusCode(), response.getStatus()); @@ -249,7 +249,7 @@ public void testMatchInfoGetWithHighlights () throws KustvaktException { @Test public void testMatchInfoGet2 () throws KustvaktException { Response response = target().path(API_VERSION) - .path("corpus/GOE/AGA/01784/p36-46/matchInfo") + .path("corpus/GOE/AGA/01784/p36-46") .queryParam("foundry", "*").request().get(); assertEquals(Status.OK.getStatusCode(), response.getStatus()); String ent = response.readEntity(String.class);