Hi All,
I am trying to Map values to the templete. I am testing web services. I need to populate response from the first rest call to another rest call as a request. I am doing in the below.
The RED color is the first POST call and I am saving the response into two values. Now I am passing the values to another POST call in YELLOW color.
I am getting the below error. Please help to solve this issue
too many arguments for method body: (bd:io.gatling.http.request.Body)io.gatling.http.request.builder.HttpRequestWithParamsBuilder
val authorization = scenario(“Authorization”)
.feed(correlationIdFeeder)
.feed(dataFeeder)
.feed(csvFeeder)
.exec(
http(“Creating tm token given an external token”)
.post(tokenization_endpoint)
.body(ELFileBody(“tokenization.json”)).asJSON
.check(status.is(200))
.check(jsonPath("$.payment_token").saveAs(“payment_token”))
.check(jsonPath("$.payment_transaction_id").saveAs(“payment_transaction_id”))
)
.exec(
http(“Authorization flow”)
.post(authorization_endpoint)
.body(ELFileBody(“authorization.json”), Map(“payment_token” → “${payment_token}”, “payment_transaction_id” → “${payment_transaction_id}”, “transaction_date” → “${current_date}”, “value” → “${amount}” ) ).asJSON
.check(status.is(200))
.check(jsonPath("$.transaction_details.transaction_status").is(“Approved”))
.check(jsonPath("$.transaction_details.transaction_status_code").is(“0x20”))
.check(jsonPath("$.transaction_details.payment_token").is("${payment_token}"))
.check(jsonPath("$.transaction_details.payment_transaction_id").is("${payment_transaction_id}"))
.check(jsonPath("$.transaction_details.transaction_date").is("${current_date}"))
)
Thank You
Murali.