I have this regex pattern, (\-?\d?)(\.?\d)*\,{1}(\-?\d+\.?\d*) for the following data
<LinearRing>
<coordinates> 46.8,16.600001 023,16.600035 -46.2000,16.60004 46,164 47.400044,-14.1 47.400043,13.8 47.400043,0 47.400024,-3.9 </coordinates>
<coordinates> 46.8,16.600032 46,16.600035 -46.2000,16.60004 46,164 47.400044,-14.1 47.400043,13.8 47.400043,0 47.400024,-3.9 </coordinates>
</LinearRing>
Due to space/gap (between 16.600001 and 023), the matching fails, I also tried adding \\s? but it is still failing,
# * def xmlData1 = above data
* match each $xmlData1/LinearRing/coordinates == '#regex ((\\-?\\d?)(\\.?\\d)*\\,{1}(\\-?\\d+\\.?\\d*)\\s?)'
Is this possible to iterate each group (of 2 values) inside the coordinates to match the above regex in Karate? Or how I can adjust my regex to match the format? only one space is allowed between each value