Open legzo opened 3 years ago
The json body { ...} is equivalent to the following assert: `body equals "{...}" Therefore, this is an assert on a string (not a json).
The error message could maybe be reduced to the different line/character in the string
error: Assert Body Value
--> ./integration/test-files/nominal/edito/accessory-orange.hurl:38:1
|
38 | "name": "Julien",
| ^ actual value is <Frieda",>
}
In assertion libraries the message is also just "expected xxx but was xxy" but (when in an IDE) there's a way to diff the contents.
Maybe it could be an option to generate a diff and pass it to any standard diff reader ?
It looks like when using body assertions there is no simple way to compare actual and expected values.
E.g. : I make a request that returns body
In my hurl file is as follows :
The output is
Would it be possible to have a simple way to diff the actual and expected ? Like what is possible with JUnit failed string comparisons.