You are here

public function RulesConditionalFrameworkTestCase::testInterceptMethod in Conditional Rules 7

Same name and namespace in other branches
  1. 8 tests/rules_conditional.test \RulesConditionalFrameworkTestCase::testInterceptMethod()

Tests intercepting a method.

File

tests/rules_conditional.test, line 79
SimpleTest testing suites.

Class

RulesConditionalFrameworkTestCase
Framework tests.

Code

public function testInterceptMethod() {
  $message = 'Test magic method is intercepted.';
  try {
    $container = new RulesConditionalTestStubContainer();
    $container
      ->test();
    $this
      ->fail($message);
  } catch (Exception $ex) {
    $this
      ->assertEqual('intercept', $ex
      ->getMessage(), $message);
  }
}