Skip to content

Commit f5dc529

Browse files
committed
#9: * fix 034-scope_cancellation_double_error
1 parent f521165 commit f5dc529

File tree

1 file changed

+14
-17
lines changed

1 file changed

+14
-17
lines changed

tests/scope/034-scope_cancellation_double_error.phpt

Lines changed: 14 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
--TEST--
2-
Scope cancellation with finally handlers execution
2+
Scope cancellation with double-exception case in finally handlers execution
3+
--DESCRIPTION--
4+
This test triggers a double-exception case: first in the coroutine, and then in the onFinally handler.
35
--FILE--
46
<?php
57

@@ -64,20 +66,15 @@ start
6466
coroutines with finally handlers spawned
6567
coroutine with finally started
6668
child coroutine started
67-
scope finally handler added
68-
cancelling parent scope
6969
finally handler 3 executed
70-
finally handler 2 executed
71-
finally handler 1 executed
72-
child finally handler executed
73-
scope finally handler executed
74-
main coroutine %s: %s
75-
child coroutine cancelled: Scope cancelled with finally
76-
testing finally handler order in hierarchy
77-
hierarchy coroutine started
78-
cancelling parent scope in hierarchy
79-
hierarchy coroutine finally
80-
child scope finally
81-
parent scope finally
82-
hierarchy cancelled: Hierarchy cancel
83-
end
70+
71+
Fatal error: Uncaught Error: Call to undefined function some_function() in %s:%d
72+
Stack trace:
73+
#0 [internal function]: {closure:%s:%d}()
74+
#1 {main}
75+
76+
Next RuntimeException: Finally handler error in %s:%d
77+
Stack trace:
78+
#0 [internal function]: {closure:{closure:%s:%d}:%d}(Object(Async\Coroutine))
79+
#1 {main}
80+
thrown in %s on line %d

0 commit comments

Comments
 (0)