RulesActionManagerTest.php in Rules 8.3
File
tests/src/Unit/Integration/RulesAction/RulesActionManagerTest.php
View source
<?php
namespace Drupal\Tests\rules\Unit\Integration\RulesAction;
use Drupal\rules\Context\ContextDefinitionInterface;
use Drupal\Tests\rules\Unit\Integration\RulesIntegrationTestBase;
class RulesActionManagerTest extends RulesIntegrationTestBase {
public function testContextDefinitionAnnotations() {
$definitions = $this->actionManager
->getDefinitions();
foreach ($definitions as $definition) {
if (!empty($definition['context_definitions'])) {
foreach ($definition['context_definitions'] as $context_definition) {
$this
->assertInstanceOf(ContextDefinitionInterface::class, $context_definition);
}
}
}
}
}