Closed artem-zakharchenko closed 3 years ago
If the expected/actual values contain a dollar sign $ it gets treated as a string replacement sequence when the diff is wrapped in a wrapWith template string:
$
wrapWith
https://github.com/apiaryio/gavel2html/blob/8788847be0ba2aed566a13563a91c1598ce30809/src/converter.coffee#L47-L48
This can be remediated in two steps:
@wrapWith.replace
If the expected/actual values contain a dollar sign
$
it gets treated as a string replacement sequence when the diff is wrapped in awrapWith
template string:https://github.com/apiaryio/gavel2html/blob/8788847be0ba2aed566a13563a91c1598ce30809/src/converter.coffee#L47-L48
This can be remediated in two steps:
$
string character to prevent it from being treated as a string replace sequence.@wrapWith.replace
call, so it ignores string replace sequences.