test($parse): ensure CSP code paths are used when testing

(Port from commit 1 in #9048)

Previously, the test suite was not actually taking CSP-mode paths when we were
expecting it to.