function ReactionRuleConfigTest::testGetEventNames
@covers ::getEventNames
File
-
tests/
src/ Unit/ Entity/ ReactionRuleConfigTest.php, line 50
Class
- ReactionRuleConfigTest
- @coversDefaultClass \Drupal\rules\Entity\ReactionRuleConfig @group Rules
Namespace
Drupal\Tests\rules\Unit\EntityCode
public function testGetEventNames() {
// Create a rule with a few events.
$rule = $this->createRule([
'events' => [
[
'event_name' => 'foo',
],
[
'event_name' => 'bar',
'configuration' => [
'qux' => 'baz',
],
],
],
]);
$expected = [
'foo',
'bar',
];
$this->assertSame($expected, $rule->getEventNames());
}