Hi there,
I have a method which extracts id to session:
public static HttpRequestActionBuilder postRequest() {
return createBasicPostRequest()
.check(status().is(201))
.check(jsonPath("$.ID").ofInt().exists().saveAs("id"));
}
And I have a predefined Json file which is used in subsequent request as a ElFileBody :
{
"ID": "#{id}",
"NAME": "John"
"SURNAME": "Doe"
}
I expect my request will look like this
{
"ID": 1,
"NAME": "John"
"SURNAME": "Doe"
}
but it looks like this:
{
"ID": "1",
"NAME": "John"
"SURNAME": "Doe"
}
It wraps β#{id}β from session as a String, but my API expects it to be an Int. How may I achieve id to be inserted as Int?