I tried couple of ways to make use of IF-Else conditional logic as mentioned in these two links
1 How to check additional values with if condition (using karate framework)?
[2]https://github.com/intuit/karate#conditional-logic
After trying different combinations I am still unsuccessful and I don't see other ways to make my scenario work. For better visibility and understanding I have attached screenshot.
As shown both output2.c.data and z.d.data are empty array's. Using these two references I have defined
*def output4 = (z.d.data == output2.c.data ? {pass:true} : {pass:false})
I was expecting my output - output4- to be {"pass":true}
For unknown reasons my scenario is giving me the opposite of what I am expecting.