Further aligned the contracts: name and method are named exactly alike now
authorKai Moritz <kai@juplo.de>
Sun, 22 May 2022 05:42:00 +0000 (07:42 +0200)
committerKai Moritz <kai@juplo.de>
Fri, 3 Jun 2022 11:48:44 +0000 (13:48 +0200)
spring-consumer/src/test/java/de/juplo/demos/pact/ContractTest.java
spring-consumer/target/pacts/SpringConsumer-SirenOrderProvider.json

index a148b60..6fa8b5a 100644 (file)
@@ -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());
               });
             });
index d666dde..27ff970 100644 (file)
                               "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$"
                             }
                           ]
-                        },
-                        "$.method": {
-                          "combine": "AND",
-                          "matchers": [
-                            {
-                              "match": "type"
-                            }
-                          ]
-                        },
-                        "$.name": {
-                          "combine": "AND",
-                          "matchers": [
-                            {
-                              "match": "type"
-                            }
-                          ]
                         }
                       }
                     },
                               "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$"
                             }
                           ]
-                        },
-                        "$.method": {
-                          "combine": "AND",
-                          "matchers": [
-                            {
-                              "match": "type"
-                            }
-                          ]
-                        },
-                        "$.name": {
-                          "combine": "AND",
-                          "matchers": [
-                            {
-                              "match": "type"
-                            }
-                          ]
                         }
                       }
                     }