Make billionLaughsAttackTest.billionLaughsAttackExpanded() robust
Florian Schmaus
Branch: Flowdalic/snakeyaml:make-billion-laughs-attack-test-robust
Branch: snakeyaml/snakeyaml:master
Merged
Merged pull request
Merged in make-billion-laughs-attack-test-robust (pull request #7)
The test would check for the existence of a particular string in the catched exception's message. Unfortunately, this is unreliable, at the content of the message of an runtime system exception is not part of an API contract. Gentoo ran multiple times into this: See Gentoo bug #834988 [1] and #780663 [2], cauing Gentoo to carry around a patch for this [3]. This commit should make it possible for Gentoo to drop the patch while additionaly increases the false negative rate of snakeyaml's unit test suite.
1: https://bugs.gentoo.org/835988 2: https://bugs.gentoo.org/780663 3: https://gitweb.gentoo.org/repo/gentoo.git/tree/dev-java/snakeyaml/files/snakeyaml-1.28-fix-test-check.patch?id=39c97bc4f6f26fcd3aca46c9df106be53107b40b