diff --git a/composer.json b/composer.json index 8f8f170..3f6158c 100644 --- a/composer.json +++ b/composer.json @@ -14,7 +14,7 @@ "ext-parallel": "*", "react-parallel/event-loop": "dev-master as 2.0", "react/event-loop": "^1.1", - "react/promise": "^2.7", + "react/promise": "^2.7 || ^3.0", "wyrihaximus/constants": "^1.6" }, "require-dev": { diff --git a/composer.lock b/composer.lock index 2289ba8..b018fd0 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "d2ead3bcdffb03a5011820a9ccefb05a", + "content-hash": "0ed1b0566043aebf3de9d769aff78446", "packages": [ { "name": "lcobucci/clock", @@ -382,23 +382,24 @@ }, { "name": "react/promise", - "version": "v2.11.0", + "version": "v3.1.0", "source": { "type": "git", "url": "https://github.com/reactphp/promise.git", - "reference": "1a8460931ea36dc5c76838fec5734d55c88c6831" + "reference": "e563d55d1641de1dea9f5e84f3cccc66d2bfe02c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/reactphp/promise/zipball/1a8460931ea36dc5c76838fec5734d55c88c6831", - "reference": "1a8460931ea36dc5c76838fec5734d55c88c6831", + "url": "https://api.github.com/repos/reactphp/promise/zipball/e563d55d1641de1dea9f5e84f3cccc66d2bfe02c", + "reference": "e563d55d1641de1dea9f5e84f3cccc66d2bfe02c", "shasum": "" }, "require": { - "php": ">=5.4.0" + "php": ">=7.1.0" }, "require-dev": { - "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36" + "phpstan/phpstan": "1.10.39 || 1.4.10", + "phpunit/phpunit": "^9.6 || ^7.5" }, "type": "library", "autoload": { @@ -442,7 +443,7 @@ ], "support": { "issues": "https://github.com/reactphp/promise/issues", - "source": "https://github.com/reactphp/promise/tree/v2.11.0" + "source": "https://github.com/reactphp/promise/tree/v3.1.0" }, "funding": [ { @@ -450,7 +451,7 @@ "type": "open_collective" } ], - "time": "2023-11-16T16:16:50+00:00" + "time": "2023-11-16T16:21:57+00:00" }, { "name": "reactivex/rxphp", diff --git a/tests/RuntimeTest.php b/tests/RuntimeTest.php index e9c06e3..a6f8075 100644 --- a/tests/RuntimeTest.php +++ b/tests/RuntimeTest.php @@ -6,18 +6,15 @@ use parallel\Runtime\Error\Closed; use React\EventLoop\Loop; -use React\Promise\ExtendedPromiseInterface; use ReactParallel\EventLoop\EventLoopBridge; use ReactParallel\Runtime\Runtime; use TheOrville\Exceptions\LatchcombException; use WyriHaximus\AsyncTestUtilities\AsyncTestCase; -use function assert; use function React\Async\await; use function sleep; use function WyriHaximus\React\timedPromise; -/** @internal */ final class RuntimeTest extends AsyncTestCase { /** @test */ @@ -30,7 +27,6 @@ public function convertSuccess(): void return 3; }); - assert($promise instanceof ExtendedPromiseInterface); $promise->always(static function () use ($runtime): void { $runtime->kill(); @@ -54,7 +50,6 @@ public function convertFailure(): void throw new LatchcombException('Rethrow exception'); }); - assert($promise instanceof ExtendedPromiseInterface); $promise->always(static function () use ($runtime): void { $runtime->close(); @@ -78,7 +73,6 @@ public function weClosedTheThread(): void return 3; }); }); - assert($promise instanceof ExtendedPromiseInterface); Loop::futureTick(static function () use ($runtime): void { $runtime->close(); @@ -100,7 +94,6 @@ public function weKilledTheThread(): void return 3; }); }); - assert($promise instanceof ExtendedPromiseInterface); Loop::futureTick(static function () use ($runtime): void { $runtime->kill();