Karate comparing 2 arrays of numbers

Viewed 28

I am getting one array from an API response and the second is a list of calculated values. I would want to match both arrays but the values could be slightly different due to rounding, so I'd like to do something like this

Values of array 1 included between values of array 2 +- 0.1
ie array2[i] - 0.1 < array1[i] < array[2] + 0.1

Is there a way to do that with karate match without having to write a javascript method to do the compare?

1 Answers
Related