{
object.stringValue("name","update");
object.stringValue("method", "PUT");
- object.matchUrl2("href", "orders", Matchers.regexp("\\d+", "1234").getValue());
+ object.matchUrl2("href", "orders", Matchers.regexp("\\d+", "1234").getMatcher());
});
actionsArray.object(object ->
{
object.stringValue("name","delete");
object.stringValue("method", "DELETE");
- object.matchUrl2("href", "orders", Matchers.regexp("\\d+", "1234").getValue());
+ object.matchUrl2("href", "orders", Matchers.regexp("\\d+", "1234").getMatcher());
});
});
entities.array("class", classArray ->
},
"$.entities[*][0].href": {
"example": "http://localhost:8080/orders/1234",
- "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$",
+ "regex": ".*\\/(\\Qorders\\E\\/\\d+)$",
"type": "MockServerURL"
},
"$.entities[*][1].href": {
"example": "http://localhost:8080/orders/1234",
- "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$",
+ "regex": ".*\\/(\\Qorders\\E\\/\\d+)$",
"type": "MockServerURL"
},
"$.links[0].href": {
"generators": {
"$.href": {
"example": "http://localhost:8080/orders/1234",
- "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$",
+ "regex": ".*\\/(\\Qorders\\E\\/\\d+)$",
"type": "MockServerURL"
}
},
"matchers": [
{
"match": "regex",
- "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$"
+ "regex": ".*\\/(\\Qorders\\E\\/\\d+)$"
}
]
}
"generators": {
"$.href": {
"example": "http://localhost:8080/orders/1234",
- "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$",
+ "regex": ".*\\/(\\Qorders\\E\\/\\d+)$",
"type": "MockServerURL"
}
},
"matchers": [
{
"match": "regex",
- "regex": ".*\\/(\\Qorders\\E\\/\\Q1234\\E)$"
+ "regex": ".*\\/(\\Qorders\\E\\/\\d+)$"
}
]
}