diff options
author | Morten Tokle <mortent@verizonmedia.com> | 2019-07-31 16:06:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-31 16:06:29 +0200 |
commit | 715a2a222d3f8a3d4deee2c9e461a80cbcd125e6 (patch) | |
tree | 9958d6979dafaab5a447020ba30974f175f1ccf1 | |
parent | d92781acd939d57b8447a4cddbbab7e9b93350d7 (diff) | |
parent | 43ae4056b6d91dd1972a5c2d6c88305c727e3af3 (diff) |
Merge pull request #10143 from vespa-engine/mortent/ignore-json-order
Ignore order in serialized JSON
-rw-r--r-- | application/pom.xml | 7 | ||||
-rw-r--r-- | application/src/test/java/com/yahoo/application/container/ContainerModelEvaluationTest.java | 3 |
2 files changed, 8 insertions, 2 deletions
diff --git a/application/pom.xml b/application/pom.xml index f9f3e8394af..20b754fc236 100644 --- a/application/pom.xml +++ b/application/pom.xml @@ -134,7 +134,12 @@ <artifactId>httpclient</artifactId> <scope>test</scope> </dependency> - + <dependency> + <groupId>com.yahoo.vespa</groupId> + <artifactId>testutil</artifactId> + <version>${project.version}</version> + <scope>test</scope> + </dependency> <!-- These dependencies are necessary in test classpath when using jdisc_http_filters --> <dependency> diff --git a/application/src/test/java/com/yahoo/application/container/ContainerModelEvaluationTest.java b/application/src/test/java/com/yahoo/application/container/ContainerModelEvaluationTest.java index 66a7ae579fa..6a2b7945d73 100644 --- a/application/src/test/java/com/yahoo/application/container/ContainerModelEvaluationTest.java +++ b/application/src/test/java/com/yahoo/application/container/ContainerModelEvaluationTest.java @@ -7,6 +7,7 @@ import com.yahoo.application.container.handler.Request; import com.yahoo.application.container.handler.Response; import com.yahoo.tensor.Tensor; import com.yahoo.tensor.TensorType; +import com.yahoo.test.json.JsonTestHelper; import org.junit.Ignore; import org.junit.Test; @@ -64,7 +65,7 @@ public class ContainerModelEvaluationTest { private void assertResponse(String url, String expectedResponse, JDisc jdisc) { try { Response response = jdisc.handleRequest(new Request(url)); - assertEquals(expectedResponse, response.getBodyAsString()); + JsonTestHelper.assertJsonEquals(expectedResponse, response.getBodyAsString()); assertEquals(200, response.getStatus()); } catch (CharacterCodingException e) { |