Vishal Singh
Vishal Singh

Reputation: 21

Need to print only unmatched keys and values not whole response in case of deep comparision

I am using karate for automation testing. Also I am using * match response1 deep contains response2 for matching two responses. In the case when the responses it doesn't match it prints a lot of unwanted responses.

Is It possible in karate to make it print only the unmatched keys?. Or any replace for deep contains which do the same work in karate.

I am saying that when matching the responses it prints a lot of unwanted logs with unmatched keys. I want to do deep comparision but with logs only print unmatched keys. I am not saying it to continue assert even some not matched found.

It is very confusing as if there is an array in response object and also some other data if the values in that array in different order but same and some other values in response apart from this array doesn't match which is the reason for failures but in report it shows that comparision also which is showing the failures when comparing the responses.

Upvotes: 1

Views: 15

Answers (0)

Related Questions