-
Notifications
You must be signed in to change notification settings - Fork 110
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Lookup required PHP version from composer.json
- Loading branch information
Showing
3 changed files
with
106 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?php | ||
|
||
namespace BeyondCode\SelfDiagnosis\Tests; | ||
|
||
use Orchestra\Testbench\TestCase; | ||
use BeyondCode\SelfDiagnosis\Checks\CorrectPhpVersionIsInstalled; | ||
|
||
class CorrectPhpVersionIsInstalledTest extends TestCase | ||
{ | ||
/** @test */ | ||
public function it_detects_the_php_version_from_composer_json() | ||
{ | ||
$this->app->setBasePath(__DIR__ . '/fixtures'); | ||
|
||
$check = app(CorrectPhpVersionIsInstalled::class); | ||
|
||
$this->assertSame('7.1.3', $check->getRequiredPhpVersion()); | ||
} | ||
} |
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,61 @@ | ||
{ | ||
"name": "laravel/laravel", | ||
"description": "The Laravel Framework.", | ||
"keywords": [ | ||
"framework", | ||
"laravel" | ||
], | ||
"license": "MIT", | ||
"type": "project", | ||
"require": { | ||
"php": "^7.1.3", | ||
"fideloper/proxy": "^4.0", | ||
"laravel/framework": "5.6.*", | ||
"laravel/tinker": "^1.0" | ||
}, | ||
"require-dev": { | ||
"filp/whoops": "^2.0", | ||
"fzaninotto/faker": "^1.4", | ||
"mockery/mockery": "^1.0", | ||
"nunomaduro/collision": "^2.0", | ||
"phpunit/phpunit": "^7.0" | ||
}, | ||
"autoload": { | ||
"classmap": [ | ||
"database/seeds", | ||
"database/factories" | ||
], | ||
"psr-4": { | ||
"App\\": "app/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Tests\\": "tests/" | ||
} | ||
}, | ||
"extra": { | ||
"laravel": { | ||
"dont-discover": [] | ||
} | ||
}, | ||
"scripts": { | ||
"post-root-package-install": [ | ||
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\"" | ||
], | ||
"post-create-project-cmd": [ | ||
"@php artisan key:generate" | ||
], | ||
"post-autoload-dump": [ | ||
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump", | ||
"@php artisan package:discover" | ||
] | ||
}, | ||
"config": { | ||
"preferred-install": "dist", | ||
"sort-packages": true, | ||
"optimize-autoloader": true | ||
}, | ||
"minimum-stability": "dev", | ||
"prefer-stable": true | ||
} |