Skip to content
Snippets Groups Projects
Commit bea5ccb1 authored by catch's avatar catch
Browse files

Issue #3402548 by alexpott, mikelutz, el7cosmos: YamlFileLoaderTest fails if...

Issue #3402548 by alexpott, mikelutz, el7cosmos: YamlFileLoaderTest fails if you have PECL yaml installed

(cherry picked from commit aac47f0d)
parent d15c4314
No related branches found
No related tags found
20 merge requests!8376Drupal views: adding more granularity to the ‘use ajax’ functionality,!8300Issue #3443586 View area displays even when parent view has no results.,!7567Issue #3153723 by quietone, Hardik_Patel_12: Change the scaffolding...,!7565Issue #3153723 by quietone, Hardik_Patel_12: Change the scaffolding...,!7509Change label "Block description" to "Block type",!7344Issue #3292350 by O'Briat, KlemenDEV, hswong3i, smustgrave, quietone: Update...,!6922Issue #3412959 by quietone, smustgrave, longwave: Fix 12 'un' words,!6848Issue #3417553 by longwave: Remove withConsecutive() in CacheCollectorTest,!6720Revert "Issue #3358581 by pfrenssen, _tarik_, a.dmitriiev, smustgrave:...,!6560Update ClaroPreRender.php, confirming classes provided are in array format,!6528Issue #3414261 by catch: Add authenticated user umami performance tests,!6501Issue #3263668 by omkar-pd, Wim Leers, hooroomoo: Re-enable inline form errors...,!6354Draft: Issue #3380392 by phma: Updating language weight from the overview reverts label if translated,!6324Issue #3416723 by Ludo.R: Provide a "node type" views default argument,!6119Issue #3405704 by Spokje, longwave: symfony/psr-http-message-bridge major version bump,!5950Issue #3403653 by alexpott, longwave: Incorporate improvements to how contrib runs PHPStan to core,!5858Issue #3401971 by fjgarlin: Test-only job shouldn't require constant rebases...,!5716Draft: Issue #3401102 by Spokje, longwave, smustgrave: Nightwatch artifacts on GitLab not retained,!5674Transaction autocommit during shutdown relies on unreliable object destruction order,!5644Issue #3395563 by nireneko, marvil07, lauriii, borisson_, smustgrave, Wim...
Pipeline #52363 passed
Pipeline: drupal

#52364

    ......@@ -450,8 +450,8 @@ private function validate($content, $file)
    throw new InvalidArgumentException(sprintf('The service file "%s" is not valid. It should contain an array. Check your YAML syntax.', $file));
    }
    if ($invalid_keys = array_diff_key($content, array('parameters' => 1, 'services' => 1))) {
    throw new InvalidArgumentException(sprintf('The service file "%s" is not valid: it contains invalid keys %s. Services have to be added under "services" and Parameters under "parameters".', $file, $invalid_keys));
    if ($invalid_keys = array_keys(array_diff_key($content, array('parameters' => 1, 'services' => 1)))) {
    throw new InvalidArgumentException(sprintf('The service file "%s" is not valid: it contains invalid root key(s) "%s". Services have to be added under "services" and Parameters under "parameters".', $file, implode('", "', $invalid_keys)));
    }
    return $content;
    ......
    ......@@ -171,10 +171,16 @@ public function providerTestExceptions() {
    ],
    'YAML must be valid' => [<<<YAML
    do not:
    do this for the love of Foo Bar!
    do: this: for the love of Foo Bar!
    YAML,
    'The file "vfs://drupal/modules/example/example.yml" does not contain valid YAML',
    ],
    'YAML must have expected keys' => [<<<YAML
    "do not":
    do: this
    YAML,
    'The service file "vfs://drupal/modules/example/example.yml" is not valid: it contains invalid root key(s) "do not". Services have to be added under "services" and Parameters under "parameters".',
    ],
    ];
    }
    ......
    • catch @catch

      mentioned in commit 2155f016

      ·

      mentioned in commit 2155f016

      Toggle commit list
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Please register or to comment