protected function CategoryAutocompleteTest::setUp in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/block/tests/src/Unit/CategoryAutocompleteTest.php \Drupal\Tests\block\Unit\CategoryAutocompleteTest::setUp()
Overrides UnitTestCase::setUp
File
- core/
modules/ block/ tests/ src/ Unit/ CategoryAutocompleteTest.php, line 28 - Contains \Drupal\Tests\block\Unit\CategoryAutocompleteTest.
Class
- CategoryAutocompleteTest
- @coversDefaultClass \Drupal\block\Controller\CategoryAutocompleteController @group block
Namespace
Drupal\Tests\block\UnitCode
protected function setUp() {
$block_manager = $this
->getMock('Drupal\\Core\\Block\\BlockManagerInterface');
$block_manager
->expects($this
->any())
->method('getCategories')
->will($this
->returnValue(array(
'Comment',
'Node',
'None & Such',
'User',
)));
$this->autocompleteController = new CategoryAutocompleteController($block_manager);
}