-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathRouteRebuilderTest.php
More file actions
41 lines (34 loc) · 977 Bytes
/
RouteRebuilderTest.php
File metadata and controls
41 lines (34 loc) · 977 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
namespace Drupal\Tests\trustee_profile\Kernel\Plugin\InstallTask;
use Drupal\Core\Routing\RouteBuilderInterface;
use Drupal\KernelTests\KernelTestBase;
use Drupal\trustee_profile\Plugin\InstallTask\RouteRebuilder;
/**
* Class RouteRebuilderTest.
*/
class RouteRebuilderTest extends KernelTestBase {
/**
* {@inheritDoc}
*/
protected static $modules = [
'system',
'node',
'user',
];
/**
* {@inheritDoc}
*/
public function setup(): void {
parent::setUp();
$this->setInstallProfile('trustee_profile');
$this->installEntitySchema('user');
$this->installEntitySchema('node');
$this->installSchema('node', 'node_access');
$this->container->set('router.builder', $this->createMock(RouteBuilderInterface::class));
}
public function testRouteRebuild() {
$plugin = RouteRebuilder::create($this->container, [], '', []);
$install_state = [];
$this->assertNull($plugin->runTask($install_state));
}
}