2016-12-29 20:59:59 -06:00
|
|
|
<?php
|
2015-08-12 19:02:41 -04:00
|
|
|
|
|
|
|
namespace Amp\File\Test;
|
|
|
|
|
2017-06-20 00:06:12 -05:00
|
|
|
class EioHandleTest extends AsyncHandleTest {
|
2017-06-16 18:12:42 -05:00
|
|
|
protected function execute(callable $cb) {
|
2015-08-12 19:02:41 -04:00
|
|
|
if (\extension_loaded("eio")) {
|
2017-06-17 23:41:57 +02:00
|
|
|
\Amp\Loop::run(function () use ($cb) {
|
2016-07-21 01:33:03 +02:00
|
|
|
\Amp\File\filesystem(new \Amp\File\EioDriver);
|
2017-03-16 22:39:49 -05:00
|
|
|
\Amp\Promise\rethrow(new \Amp\Coroutine($cb()));
|
2016-07-21 01:33:03 +02:00
|
|
|
});
|
2015-08-12 19:02:41 -04:00
|
|
|
} else {
|
|
|
|
$this->markTestSkipped(
|
|
|
|
"eio extension not loaded"
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|