Skip to content

Commit c957d77

Browse files
committed
Testing updates for travis
1 parent 8a2f001 commit c957d77

File tree

4 files changed

+19
-10
lines changed

4 files changed

+19
-10
lines changed

.travis.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ language: php
22
sudo: required
33

44
php:
5-
- 5.6
6-
- 7
5+
- 7.0
6+
- 7.1
77
- hhvm
88

99
matrix:
@@ -14,4 +14,4 @@ install:
1414
- composer install
1515

1616
script:
17-
- phpunit
17+
- vendor/bin/phpunit

composer.json

+5-2
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
}
3131
},
3232
"require": {
33-
"voryx/event-loop": "^2.0.0",
33+
"voryx/event-loop": "^2.0",
3434
"react/child-process": "^0.4.3",
35-
"reactivex/rxphp": "2.x-dev"
35+
"reactivex/rxphp": "^2.0"
3636
},
3737
"autoload-dev": {
3838
"psr-4": {
@@ -42,5 +42,8 @@
4242
"files": [
4343
"vendor/reactivex/rxphp/test/helper-functions.php"
4444
]
45+
},
46+
"require-dev": {
47+
"phpunit/phpunit": "^5.5"
4548
}
4649
}

examples/command.php

+11-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,16 @@
11
<?php
22

3-
require __DIR__ . '/../vendor/autoload.php';
3+
use Rx\Observable;
4+
use Rx\React\ProcessSubject;
5+
use Rx\Thruway\Client;
46

5-
$process = new \Rx\React\ProcessSubject('echo foo');
7+
require __DIR__ . '/../vendor/autoload.php';
68

7-
$process->subscribe(function ($x) {
8-
echo $x;
9+
$top = (new ProcessSubject('top -l 1'))->repeatWhen(function (Observable $attempts) {
10+
return $attempts->delay(3000);
911
});
12+
13+
14+
(new Client('ws://127.0.0.1:9090', 'realm1'))->publish('top.of.the.morning', $top);
15+
16+
$top->subscribe('print_r');

src/ProcessSubject.php

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
use React\ChildProcess\Process;
66
use React\EventLoop\LoopInterface;
77
use Rx\Disposable\CallbackDisposable;
8-
use Rx\Disposable\EmptyDisposable;
98
use Rx\DisposableInterface;
109
use Rx\ObserverInterface;
1110
use Rx\Subject\Subject;

0 commit comments

Comments
 (0)