Hi I have the following example rest assured filter written in java:
String amountSold = jsonPath.getString("book.find{it.release == '2020-09-22'}.AmountSold");
How can I replace this filter to include a variable instead of hardcoding '2020-09-22'?
CodePudding user response:
String amountSold = jsonPath
.param("rdate", '2020-09-22')
.getString("book.find{it.release == rdate}.AmountSold")