1
0
mirror of https://github.com/danog/amp.git synced 2024-12-11 17:09:40 +01:00
amp/test/Loop/UvDriverTest.php

30 lines
532 B
PHP
Raw Normal View History

2016-06-09 19:57:46 +02:00
<?php
namespace Amp\Test\Loop;
use Amp\Loop\UvDriver;
2016-06-09 19:57:46 +02:00
/**
* @requires extension uv
*/
2018-06-18 20:00:01 +02:00
class UvDriverTest extends DriverTest
{
public function getFactory(): callable
{
return function () {
return new UvDriver;
};
2016-06-09 19:57:46 +02:00
}
2018-06-18 20:00:01 +02:00
public function testHandle()
{
$handle = $this->loop->getHandle();
$this->assertTrue(\is_resource($handle) || $handle instanceof \UVLoop);
}
2017-03-15 08:32:05 +01:00
2018-06-18 20:00:01 +02:00
public function testSupported()
{
2017-03-15 08:32:05 +01:00
$this->assertTrue(UvDriver::isSupported());
}
2016-06-09 19:57:46 +02:00
}