From: Kai Moritz Date: Sun, 22 May 2022 05:42:00 +0000 (+0200) Subject: Further aligned the contracts: name and method are named exactly alike now X-Git-Url: http://juplo.de/gitweb/?a=commitdiff_plain;h=ff7842de1d2ba20877a84835f688d7e85452339f;p=demos%2Fexample-siren Further aligned the contracts: name and method are named exactly alike now --- diff --git a/spring-consumer/src/test/java/de/juplo/demos/pact/ContractTest.java b/spring-consumer/src/test/java/de/juplo/demos/pact/ContractTest.java index a148b60..6fa8b5a 100644 --- a/spring-consumer/src/test/java/de/juplo/demos/pact/ContractTest.java +++ b/spring-consumer/src/test/java/de/juplo/demos/pact/ContractTest.java @@ -66,14 +66,14 @@ public class ContractTest { actionsArray.object(object -> { - object.stringType("name","update"); - object.stringType("method", "PUT"); + object.stringValue("name","update"); + object.stringValue("method", "PUT"); object.matchUrl2("href", "orders", Matchers.regexp("\\d+", "1234").getValue()); }); actionsArray.object(object -> { - object.stringType("name","delete"); - object.stringType("method", "DELETE"); + object.stringValue("name","delete"); + object.stringValue("method", "DELETE"); object.matchUrl2("href", "orders", Matchers.regexp("\\d+", "1234").getValue()); }); }); diff --git a/spring-consumer/target/pacts/SpringConsumer-SirenOrderProvider.json b/spring-consumer/target/pacts/SpringConsumer-SirenOrderProvider.json index d666dde..27ff970 100644 --- a/spring-consumer/target/pacts/SpringConsumer-SirenOrderProvider.json +++ b/spring-consumer/target/pacts/SpringConsumer-SirenOrderProvider.json @@ -138,22 +138,6 @@ "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$" } ] - }, - "$.method": { - "combine": "AND", - "matchers": [ - { - "match": "type" - } - ] - }, - "$.name": { - "combine": "AND", - "matchers": [ - { - "match": "type" - } - ] } } }, @@ -175,22 +159,6 @@ "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$" } ] - }, - "$.method": { - "combine": "AND", - "matchers": [ - { - "match": "type" - } - ] - }, - "$.name": { - "combine": "AND", - "matchers": [ - { - "match": "type" - } - ] } } }