function RulesTestCase::testActionExecutionFails
Same name in other branches
- 8.x-3.x d7-tests/rules_test_case.test \RulesTestCase::testActionExecutionFails()
Tests executing with wrong arguments.
File
-
tests/
rules.test, line 194
Class
- RulesTestCase
- Rules test cases.
Code
public function testActionExecutionFails() {
$action = rules_action('rules_node_publish_action');
try {
$action->execute();
$this->fail("Execution hasn't created an exception.");
} catch (RulesEvaluationException $e) {
$this->pass("RulesEvaluationException was thrown: " . $e);
}
}