Skip to content

tests: Avoid invalid escaping in JSON

Simon McVittie requested to merge wip/smcv/json into main

MangoHud historically had paths like "/usr/\$LIB/..." in its JSON manifest, but this is not actually valid JSON, because JSON does not define a meaning for \$. The version of json-glib in Debian testing (Debian 13 prereleases) implements more correct / more strict JSON parsing, which correctly but perhaps unhelpfully diagnoses this as an error, breaking our test's expectations when our CI runs its tests in a recent development environment.

We were not intentionally exercising the handling of invalid JSON, so test against valid JSON here.

I've also opened https://gitlab.gnome.org/GNOME/json-glib/-/merge_requests/87 to return json-glib in non-strict mode to its previous behaviour for these strings.

Merge request reports

Loading