Skip to content

Commit f2db88d

Browse files
committed
Clean up test suite
1 parent ebb6baa commit f2db88d

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313
"autoload": {
1414
"psr-4": { "Clue\\React\\Ssdp\\": "src/" }
1515
},
16+
"autoload-dev": {
17+
"psr-4": { "Clue\\Tests\\React\\Ssdp\\": "tests/" }
18+
},
1619
"require": {
1720
"php": ">=5.3",
1821
"clue/multicast-react": "^1.0 || ^0.2",

phpunit.xml.dist

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22

3-
<phpunit bootstrap="tests/bootstrap.php"
4-
colors="true"
5-
convertErrorsToExceptions="true"
6-
convertNoticesToExceptions="true"
7-
convertWarningsToExceptions="true"
8-
>
3+
<phpunit bootstrap="vendor/autoload.php" colors="true">
94
<testsuites>
105
<testsuite name="SSDP Test Suite">
116
<directory>./tests/</directory>

tests/ClientTest.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
<?php
22

3+
namespace Clue\Tests\React\Ssdp;
4+
35
use Clue\React\Ssdp\Client;
46
use React\EventLoop\Factory;
57

@@ -37,7 +39,7 @@ interface_exists('React\EventLoop\TimerInterface') ? 'React\EventLoop\TimerInter
3739

3840
$this->assertInstanceOf('React\Promise\PromiseInterface', $promise);
3941

40-
if (!($promise instanceof React\Promise\CancellablePromiseInterface)) {
42+
if (!($promise instanceof \React\Promise\CancellablePromiseInterface)) {
4143
$this->markTestSkipped();
4244
}
4345

tests/bootstrap.php renamed to tests/TestCase.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?php
22

3-
require __DIR__ . '/../vendor/autoload.php';
3+
namespace Clue\Tests\React\Ssdp;
44

5-
class TestCase extends PHPUnit\Framework\TestCase
5+
class TestCase extends \PHPUnit\Framework\TestCase
66
{
77
protected function expectCallableOnce()
88
{

0 commit comments

Comments
 (0)