protected function Validator::getTransitionFromStates in Workbench Moderation 8.2
Same name and namespace in other branches
- 8 tests/src/Unit/StateTransitionValidationTest.php \Drupal\Tests\workbench_moderation\Unit\Validator::getTransitionFromStates()
@inheritDoc
Overrides StateTransitionValidation::getTransitionFromStates
File
- tests/
src/ Unit/ StateTransitionValidationTest.php, line 246
Class
- Validator
- Testable subclass for selected tests.
Namespace
Drupal\Tests\workbench_moderation\UnitCode
protected function getTransitionFromStates($from, $to) {
if ($from == 'draft' && $to == 'draft') {
return $this
->transitionStorage()
->loadMultiple([
'draft__draft',
])[0];
}
}