2019-09-06 23:53:10 +08:00

28 lines
468 B
PHP
Executable File

--TEST--
global_function: swoole_event_write
--FILE--
<?php
require_once __DIR__ . '/../include/bootstrap.php';
swoole_event_defer(function () {
echo "defer [1]\n";
});
swoole_timer_after(100, function () {
echo "timer [1]\n";
swoole_timer_after(100, function () {
echo "timer [2]\n";
});
swoole_event_defer(function () {
echo "defer [2]\n";
});
});
swoole_event_wait();
?>
--EXPECT--
defer [1]
timer [1]
defer [2]
timer [2]