function workflow_type_test_set_definitions
Same name in other branches
- 9 core/modules/workflows/tests/modules/workflow_type_test/workflow_type_test.module \workflow_type_test_set_definitions()
- 8.9.x core/modules/workflows/tests/modules/workflow_type_test/workflow_type_test.module \workflow_type_test_set_definitions()
- 11.x core/modules/workflows/tests/modules/workflow_type_test/workflow_type_test.module \workflow_type_test_set_definitions()
Sets the type plugin definitions override and clear the cache.
Parameters
array $definitions: Definitions to set.
1 call to workflow_type_test_set_definitions()
- WorkflowAccessControlHandlerTest::testCheckCreateAccess in core/
modules/ workflows/ tests/ src/ Kernel/ WorkflowAccessControlHandlerTest.php - @covers ::checkCreateAccess
File
-
core/
modules/ workflows/ tests/ modules/ workflow_type_test/ workflow_type_test.module, line 30
Code
function workflow_type_test_set_definitions($definitions) {
\Drupal::state()->set('workflow_type_test.plugin_definitions', $definitions);
\Drupal::service('plugin.manager.workflows.type')->clearCachedDefinitions();
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.