You are here

protected function PathAliasDeleteByPathTest::setUp in Rules 8.3

Overrides RulesIntegrationTestBase::setUp

File

tests/src/Unit/Integration/RulesAction/PathAliasDeleteByPathTest.php, line 32

Class

PathAliasDeleteByPathTest
@coversDefaultClass \Drupal\rules\Plugin\RulesAction\PathAliasDeleteByPath @group RulesAction

Namespace

Drupal\Tests\rules\Unit\Integration\RulesAction

Code

protected function setUp() : void {
  parent::setUp();

  // Must enable the path_alias module.
  $this
    ->enableModule('path_alias');

  // Prepare mocked EntityStorageInterface.
  $this->aliasStorage = $this
    ->prophesize(EntityStorageInterface::class);
  $this->entityTypeManager
    ->getStorage('path_alias')
    ->willReturn($this->aliasStorage
    ->reveal());
  $this->action = $this->actionManager
    ->createInstance('rules_path_alias_delete_by_path');
}