mirror of
https://github.com/danog/amp.git
synced 2024-12-11 08:59:46 +01:00
30 lines
532 B
PHP
30 lines
532 B
PHP
<?php
|
|
|
|
namespace Amp\Test\Loop;
|
|
|
|
use Amp\Loop\UvDriver;
|
|
|
|
/**
|
|
* @requires extension uv
|
|
*/
|
|
class UvDriverTest extends DriverTest
|
|
{
|
|
public function getFactory(): callable
|
|
{
|
|
return function () {
|
|
return new UvDriver;
|
|
};
|
|
}
|
|
|
|
public function testHandle()
|
|
{
|
|
$handle = $this->loop->getHandle();
|
|
$this->assertTrue(\is_resource($handle) || $handle instanceof \UVLoop);
|
|
}
|
|
|
|
public function testSupported()
|
|
{
|
|
$this->assertTrue(UvDriver::isSupported());
|
|
}
|
|
}
|