Skip to content

Commit

Permalink
Enable method interception in rayaop test
Browse files Browse the repository at this point in the history
Added a line to activate method interception in the '001-rayaop-basic.phpt' test to ensure that interceptors properly modify method execution. This change ensures the test accurately reflects expected behavior when interception is enabled and helps validate interceptor functionality.
  • Loading branch information
koriym committed Dec 7, 2024
1 parent 7bffe61 commit e9e3c72
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/001-rayaop-basic.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ var_dump(method_intercept_init());
// Register the interceptor
var_dump(method_intercept('TestClass', 'testMethod', new TestInterceptor()));

11method_intercept_enable(true);

$test = new TestClass();
echo $test->testMethod(" method called") . "\n";

Expand All @@ -44,4 +46,4 @@ bool(true)
bool(true)
bool(true)
Intercepted: Original method called
Original method called without interception
Original method called without interception

0 comments on commit e9e3c72

Please sign in to comment.