Source

pecl-ev / tests / 08_priority.phpt

Diff from to

File tests/08_priority.phpt

 $t1 = new EvTimer(-1, 0, function ($w, $r) { echo "ok 3\n"; });
 $t1->priority = 1;
 
-$i2 = new EvIdle(function ($w, $r) { echo ev_iteration() == 1 ? "" : "not ", "ok 2\n"; $w->stop(); });
+$i2 = new EvIdle(function ($w, $r) { echo Ev::iteration() == 1 ? "" : "not ", "ok 2\n"; $w->stop(); });
 $i2->priority = 10;
-$i3 = new EvIdle(function ($w, $r) { echo ev_iteration() == 3 ? "" : "not ", "ok 7\n"; $w->stop(); });
-$i1 = new EvIdle(function ($w, $r) { echo ev_iteration() == 2 ? "" : "not ", "ok 6\n"; $w->stop(); });
+$i3 = new EvIdle(function ($w, $r) { echo Ev::iteration() == 3 ? "" : "not ", "ok 7\n"; $w->stop(); });
+$i1 = new EvIdle(function ($w, $r) { echo Ev::iteration() == 2 ? "" : "not ", "ok 6\n"; $w->stop(); });
 $i1->priority = 1;
-$i_ = new EvIdle(function ($w, $r) { echo ev_iteration() == 4 ? "" : "not ", "ok 8\n"; $w->stop(); });
+$i_ = new EvIdle(function ($w, $r) { echo Ev::iteration() == 4 ? "" : "not ", "ok 8\n"; $w->stop(); });
 $i_->priority = -1;
 
 $t0->start();
 $i_->start();
 
 echo "ok 1\n";
-ev_run();
+Ev::run();
 echo "ok 9\n";
 ?>
 --EXPECT--