Moved code a bit
This commit is contained in:
@@ -1,18 +0,0 @@
|
||||
org.springframework.cloud.contract.spec.Contract.make {
|
||||
request {
|
||||
method 'POST'
|
||||
url('/users') {
|
||||
|
||||
}
|
||||
headers {
|
||||
header 'Content-Type': 'application/json'
|
||||
}
|
||||
body '''{ "login" : "john", "name": "John The Contract" }'''
|
||||
}
|
||||
response {
|
||||
status 200
|
||||
headers {
|
||||
header 'Location': '/users/john'
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
{
|
||||
"request" : {
|
||||
"url" : "/users",
|
||||
"method" : "POST",
|
||||
"bodyPatterns" : [ {
|
||||
"matchesJsonPath" : "$[?(@.login == 'john')]"
|
||||
}, {
|
||||
"matchesJsonPath" : "$[?(@.name == 'John The Contract')]"
|
||||
} ],
|
||||
"headers" : {
|
||||
"Content-Type" : {
|
||||
"equalTo" : "application/json"
|
||||
}
|
||||
}
|
||||
},
|
||||
"response" : {
|
||||
"status" : 200,
|
||||
"headers" : {
|
||||
"Location" : "/users/john"
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user