1
0
mirror of https://github.com/danog/parallel.git synced 2024-12-02 09:37:57 +01:00
This commit is contained in:
Aaron Piotrowski 2020-02-14 18:31:01 -06:00
parent 8b74bb33f8
commit 26f869734a
No known key found for this signature in database
GPG Key ID: ADD1EF783EDE9EEB
2 changed files with 4 additions and 4 deletions

View File

@ -6,7 +6,7 @@ use Amp\Promise;
class DefaultContextFactory implements ContextFactory
{
function create($script): Context
public function create($script): Context
{
/**
* Creates a thread if ext-parallel is installed, otherwise creates a child process.
@ -25,7 +25,7 @@ class DefaultContextFactory implements ContextFactory
*
* @inheritdoc
*/
function run($script): Promise
public function run($script): Promise
{
if (Parallel::isSupported()) {
return Parallel::run($script);
@ -33,4 +33,4 @@ class DefaultContextFactory implements ContextFactory
return Process::run($script);
}
}
}

View File

@ -7,7 +7,7 @@ use Amp\Parallel\Context\DefaultContextFactory;
use Amp\Parallel\Sync\ContextPanicError;
use Amp\PHPUnit\AsyncTestCase;
class DefaultWorkerFactoryTest extends AsyncTestCase
class DefaultContextFactoryTest extends AsyncTestCase
{
public function testCreate(): void
{