diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 7d9ef15..aebfe9c 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -80,7 +80,8 @@ jobs: integrationTest \ --tests '*BatchUploaderIntegrationTest*' \ --tests '*ChallengeAPIIntegrationTest*' \ - --tests '*ProjectAPIIntegrationTest*' + --tests '*ProjectAPIIntegrationTest*' \ + --tests '*TaskAPIIntegrationTest*' validation: name: "Gradle Validation" diff --git a/src/integrationTest/java/org/maproulette/client/api/TaskAPIIntegrationTest.java b/src/integrationTest/java/org/maproulette/client/api/TaskAPIIntegrationTest.java index c8c6c3c..839febb 100644 --- a/src/integrationTest/java/org/maproulette/client/api/TaskAPIIntegrationTest.java +++ b/src/integrationTest/java/org/maproulette/client/api/TaskAPIIntegrationTest.java @@ -100,7 +100,7 @@ public void resetGeometryTest() throws MapRouletteException .get(updatedTask.getId()); Assertions.assertTrue(retrievedUpdatedTask.isPresent()); - Assertions.assertEquals("{\"features\":[" + Assertions.assertEquals("{\"type\":\"FeatureCollection\",\"features\":[" + String.format(TestConstants.FEATURE_STRING, 3.1, 4.2, UPDATED_GEOMETRY) + "]}", retrievedUpdatedTask.get().getGeometries().toString()); } @@ -134,7 +134,7 @@ public void updateTest() throws MapRouletteException this.compare(updatedTask, retrievedUpdatedTask.get()); Assertions .assertEquals( - "{\"features\":[" + "{\"type\":\"FeatureCollection\",\"features\":[" + String.format( TestConstants.FEATURE_STRING, 1.1, 2.2, DEFAULT_GEOMETRY) + "," @@ -151,7 +151,8 @@ private void compare(final Task task1, final Task task2) Assertions.assertEquals(ChallengePriority.HIGH, task2.getPriority()); Assertions.assertEquals(task1.getParent(), task2.getParent()); Assertions.assertEquals(task1.getInstruction(), task2.getInstruction()); - Assertions.assertEquals(task1.getGeometries(), task2.getGeometries()); + Assertions.assertEquals(task1.getGeometries().get("features"), + task2.getGeometries().get("features")); } private Task getDefaultTask(final String name)