diff options
Diffstat (limited to 'unit_tests/scripts')
| -rw-r--r-- | unit_tests/scripts/lane/uncooperative_shutdown.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/unit_tests/scripts/lane/uncooperative_shutdown.lua b/unit_tests/scripts/lane/uncooperative_shutdown.lua index 51e5762..89e1ff8 100644 --- a/unit_tests/scripts/lane/uncooperative_shutdown.lua +++ b/unit_tests/scripts/lane/uncooperative_shutdown.lua | |||
| @@ -8,7 +8,7 @@ local lanes = require "lanes".configure{shutdown_timeout = 0.001, on_state_creat | |||
| 8 | -- launch lanes that blocks forever | 8 | -- launch lanes that blocks forever |
| 9 | local lane = function() | 9 | local lane = function() |
| 10 | local fixture = require "fixture" | 10 | local fixture = require "fixture" |
| 11 | fixture.forever() | 11 | fixture.sleep_for() |
| 12 | end | 12 | end |
| 13 | 13 | ||
| 14 | -- the generator | 14 | -- the generator |
| @@ -20,5 +20,5 @@ local h1 = g1() | |||
| 20 | -- wait until the lane is running | 20 | -- wait until the lane is running |
| 21 | repeat until h1.status == "running" | 21 | repeat until h1.status == "running" |
| 22 | 22 | ||
| 23 | -- let the script end, Lanes should throw std::logic_error because the lane did not gracefully terminate | 23 | -- this finalizer returns an error string that telling Universe::__gc will use to raise an error when it detects the uncooperative lane |
| 24 | lanes.finally(fixture.throwing_finalizer) | 24 | lanes.finally(fixture.throwing_finalizer) |
