function ConfigValidation::validateSequence
Same name in other branches
- 9 core/modules/config/tests/config_test/src/ConfigValidation.php \Drupal\config_test\ConfigValidation::validateSequence()
- 10 core/modules/config/tests/config_test/src/ConfigValidation.php \Drupal\config_test\ConfigValidation::validateSequence()
- 11.x core/modules/config/tests/config_test/src/ConfigValidation.php \Drupal\config_test\ConfigValidation::validateSequence()
Validates a sequence.
Parameters
array $sequence: The data to validate.
\Symfony\Component\Validator\Context\ExecutionContextInterface $context: The validation execution context.
File
-
core/
modules/ config/ tests/ config_test/ src/ ConfigValidation.php, line 93
Class
- ConfigValidation
- Provides a collection of validation callbacks for testing purposes.
Namespace
Drupal\config_testCode
public static function validateSequence($sequence, ExecutionContextInterface $context) {
if (isset($sequence['invalid-key'])) {
$context->addViolation('Invalid giraffe key.');
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.