1
0
mirror of https://github.com/danog/process.git synced 2024-11-26 20:24:43 +01:00

Exclude tests against Libevent and Uv if the extensions are not loaded.

This commit is contained in:
Edoardo Biraghi 2015-09-11 17:21:42 +02:00
parent 096c908973
commit f709600db5
2 changed files with 15 additions and 3 deletions

View File

@ -6,8 +6,14 @@ use Amp\LibeventReactor;
class LibeventReactorProcessTest extends AbstractProcessTest {
public function setUp(){
\Amp\reactor(new LibeventReactor());
protected function setUp() {
if (extension_loaded("libevent")) {
\Amp\reactor($assign = new LibeventReactor);
} else {
$this->markTestSkipped(
"libevent extension not loaded"
);
}
}
public function testReactor() {

View File

@ -7,7 +7,13 @@ use Amp\UvReactor;
class UvReactorProcessTest extends AbstractProcessTest {
public function setUp(){
\Amp\reactor(new UvReactor());
if (extension_loaded("uv")) {
\Amp\reactor($assign = new UvReactor);
} else {
$this->markTestSkipped(
"php-uv extension not loaded"
);
}
}
public function testReactor() {