Since PHP 7 the preg engine uses a just in time compiler. This one can cause strange issues:
https://bugs.php.net/bug.php?id=70110
When a YAML file contains a value that consists of a lot of newlines, we're affected.
We've been affected by the PHP bug until Drupal 8.4, where the symfony components have been updated to a newer version in #2712647: Update Symfony components to ~3.2. As we want to ensure we'll not encounter the same problem again this issue is only about adding the test that used to fail in Drupal 8.3.x. The problem itself has been fixed in Symfony.