Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1st step rebuilding: add interfaces, refactors of traits, update over…
…head
- Loading branch information
Showing
25 changed files
with
352 additions
and
311 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,20 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" bootstrap="vendor/autoload.php" backupGlobals="false" backupStaticAttributes="false" colors="true" verbose="true" convertErrorsToExceptions="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd"> | ||
<coverage> | ||
<include> | ||
<directory>src/</directory> | ||
</include> | ||
<report> | ||
<html outputDirectory="./report" lowUpperBound="50" highLowerBound="80"/> | ||
</report> | ||
</coverage> | ||
<testsuites> | ||
<testsuite name="Packager"> | ||
<directory suffix=".php">./tests/</directory> | ||
</testsuite> | ||
</testsuites> | ||
<logging/> | ||
<coverage> | ||
<include> | ||
<directory>src/</directory> | ||
</include> | ||
<report> | ||
<html outputDirectory="./report" lowUpperBound="50" highLowerBound="80"/> | ||
</report> | ||
</coverage> | ||
<testsuites> | ||
<testsuite name="unit"> | ||
<directory suffix=".php">./tests/Unit</directory> | ||
</testsuite> | ||
<testsuite name="integration"> | ||
<directory suffix=".php">./tests/Integration</directory> | ||
</testsuite> | ||
</testsuites> | ||
<logging/> | ||
</phpunit> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace JeroenG\Packager; | ||
|
||
use Symfony\Component\Process\Process; | ||
|
||
final class CommandRunner implements CommandRunnerInterface | ||
{ | ||
public function run(array $commandInput): bool | ||
{ | ||
$process = new Process($commandInput, base_path()); | ||
$process->setTimeout((float) config('packager.timeout')); | ||
$process->run(); | ||
|
||
return $process->getExitCode() === 0; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace JeroenG\Packager; | ||
|
||
interface CommandRunnerInterface | ||
{ | ||
public function run(array $commandInput): bool; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.