public function ControllerResolverTest::testGetControllerFromDefinition in Drupal 10
Same name and namespace in other branches
- 8 core/tests/Drupal/Tests/Core/Controller/ControllerResolverTest.php \Drupal\Tests\Core\Controller\ControllerResolverTest::testGetControllerFromDefinition()
- 9 core/tests/Drupal/Tests/Core/Controller/ControllerResolverTest.php \Drupal\Tests\Core\Controller\ControllerResolverTest::testGetControllerFromDefinition()
Tests getControllerFromDefinition().
@dataProvider providerTestGetControllerFromDefinition
File
- core/
tests/ Drupal/ Tests/ Core/ Controller/ ControllerResolverTest.php, line 140 - Contains \Drupal\Tests\Core\Controller\ControllerResolverTest.
Class
- ControllerResolverTest
- @coversDefaultClass \Drupal\Core\Controller\ControllerResolver @group Controller
Namespace
Drupal\Tests\Core\ControllerCode
public function testGetControllerFromDefinition($definition, $output) {
$this->container
->set('invoke_service', new MockInvokeController());
$controller = $this->controllerResolver
->getControllerFromDefinition($definition);
$this
->assertCallableController($controller, NULL, $output);
}