From 8aec0daab16aa8510fc26155777212d584f0cc8a Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:18:06 +0100 Subject: [PATCH 01/12] PHP 8 Support --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 97b4144b..07e490b8 100644 --- a/composer.json +++ b/composer.json @@ -10,12 +10,12 @@ } ], "require": { - "php": "^7.3", + "php": "^7.3|^8.0", "symfony/console": "^4.0|^5.0", "symfony/process": "^4.2|^5.0" }, "require-dev": { - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^8.0|^9.3" }, "bin": [ "bin/laravel" From 7afb49bc4c4ee9d660eadee2b83c193652d02bf9 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:19:28 +0100 Subject: [PATCH 02/12] Update CI --- .github/workflows/tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index dccf4b56..ab03edaf 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,7 +13,7 @@ jobs: strategy: fail-fast: true matrix: - php: [7.3, 7.4] + php: [7.3, 7.4, ^8.0] name: PHP ${{ matrix.php }} @@ -41,7 +41,7 @@ jobs: strategy: fail-fast: true matrix: - php: [7.3, 7.4] + php: [7.3, 7.4, ^8.0] name: PHP ${{ matrix.php }} - Windows From ac5f1e0c288f3f4730b8ad92a67b0698689d2d40 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:23:07 +0100 Subject: [PATCH 03/12] Remove filter for phpunit --- phpunit.xml.dist | 5 ----- 1 file changed, 5 deletions(-) diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 31e2ad96..f5a61104 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -18,9 +18,4 @@ ./tests/scaffolds - - - ./src - - From bedca26bf5e7850fe24c46310c72a46a10173b02 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:29:53 +0100 Subject: [PATCH 04/12] Dump error output --- tests/NewCommandTest.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/NewCommandTest.php b/tests/NewCommandTest.php index 52c5939d..505922b4 100644 --- a/tests/NewCommandTest.php +++ b/tests/NewCommandTest.php @@ -29,6 +29,8 @@ public function test_it_can_scaffold_a_new_laravel_app() $statusCode = $tester->execute(['name' => $scaffoldDirectoryName]); + dump($tester->getErrorOutput()); + $this->assertSame(0, $statusCode); $this->assertDirectoryExists($scaffoldDirectory.'/vendor'); $this->assertFileExists($scaffoldDirectory.'/.env'); From 0ad3dc0451df9787f4144711930e1b20f6a3bec1 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:30:31 +0100 Subject: [PATCH 05/12] Disable linux builds --- .github/workflows/tests.yml | 54 ++++++++++++++++++------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index ab03edaf..40745c4f 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -7,33 +7,33 @@ on: - cron: '0 0 * * *' jobs: - linux_tests: - - runs-on: ubuntu-latest - strategy: - fail-fast: true - matrix: - php: [7.3, 7.4, ^8.0] - - name: PHP ${{ matrix.php }} - - steps: - - name: Checkout code - uses: actions/checkout@v2 - - - name: Setup PHP - uses: shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php }} - extensions: dom, curl, libxml, mbstring, zip - tools: composer:v2 - coverage: none - - - name: Install dependencies - run: composer install --no-interaction --prefer-dist - - - name: Execute tests - run: vendor/bin/phpunit --verbose +# linux_tests: +# +# runs-on: ubuntu-latest +# strategy: +# fail-fast: true +# matrix: +# php: [7.3, 7.4, ^8.0] +# +# name: PHP ${{ matrix.php }} +# +# steps: +# - name: Checkout code +# uses: actions/checkout@v2 +# +# - name: Setup PHP +# uses: shivammathur/setup-php@v2 +# with: +# php-version: ${{ matrix.php }} +# extensions: dom, curl, libxml, mbstring, zip +# tools: composer:v2 +# coverage: none +# +# - name: Install dependencies +# run: composer install --no-interaction --prefer-dist +# +# - name: Execute tests +# run: vendor/bin/phpunit --verbose windows_tests: From 42aaf4e7e01b22c70cb162e52dad29d7a8425e86 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:34:48 +0100 Subject: [PATCH 06/12] dump error output --- .github/workflows/tests.yml | 3 ++- tests/NewCommandTest.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 40745c4f..0c8fb95d 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -41,7 +41,8 @@ jobs: strategy: fail-fast: true matrix: - php: [7.3, 7.4, ^8.0] +# php: [7.3, 7.4, ^8.0] + php: [^8.0] name: PHP ${{ matrix.php }} - Windows diff --git a/tests/NewCommandTest.php b/tests/NewCommandTest.php index 505922b4..3944f9c1 100644 --- a/tests/NewCommandTest.php +++ b/tests/NewCommandTest.php @@ -29,7 +29,7 @@ public function test_it_can_scaffold_a_new_laravel_app() $statusCode = $tester->execute(['name' => $scaffoldDirectoryName]); - dump($tester->getErrorOutput()); + var_dump($tester->getErrorOutput()); $this->assertSame(0, $statusCode); $this->assertDirectoryExists($scaffoldDirectory.'/vendor'); From c9a940dd1521db71e8f45db0efb51e9c591b2a82 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 15:39:37 +0100 Subject: [PATCH 07/12] Enable stderr capture --- tests/NewCommandTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/NewCommandTest.php b/tests/NewCommandTest.php index 3944f9c1..3f9f903c 100644 --- a/tests/NewCommandTest.php +++ b/tests/NewCommandTest.php @@ -27,7 +27,7 @@ public function test_it_can_scaffold_a_new_laravel_app() $tester = new CommandTester($app->find('new')); - $statusCode = $tester->execute(['name' => $scaffoldDirectoryName]); + $statusCode = $tester->execute(['name' => $scaffoldDirectoryName], ['capture_stderr_separately' => true]); var_dump($tester->getErrorOutput()); From f4b671496f5336812b929bb28525a2eac1778828 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Thu, 29 Oct 2020 20:07:50 +0100 Subject: [PATCH 08/12] Update tests.yml --- .github/workflows/tests.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0c8fb95d..6b7b942e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,7 +13,7 @@ jobs: # strategy: # fail-fast: true # matrix: -# php: [7.3, 7.4, ^8.0] +# php: [7.3, 7.4, 8.0] # # name: PHP ${{ matrix.php }} # @@ -41,8 +41,8 @@ jobs: strategy: fail-fast: true matrix: -# php: [7.3, 7.4, ^8.0] - php: [^8.0] +# php: [7.3, 7.4, 8.0] + php: [8.0] name: PHP ${{ matrix.php }} - Windows From bcb52ecb4a84566e6ec29a9b543e66a2906ca2c8 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Fri, 30 Oct 2020 17:06:42 +0100 Subject: [PATCH 09/12] Revert stderr output --- tests/NewCommandTest.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/NewCommandTest.php b/tests/NewCommandTest.php index 3f9f903c..52c5939d 100644 --- a/tests/NewCommandTest.php +++ b/tests/NewCommandTest.php @@ -27,9 +27,7 @@ public function test_it_can_scaffold_a_new_laravel_app() $tester = new CommandTester($app->find('new')); - $statusCode = $tester->execute(['name' => $scaffoldDirectoryName], ['capture_stderr_separately' => true]); - - var_dump($tester->getErrorOutput()); + $statusCode = $tester->execute(['name' => $scaffoldDirectoryName]); $this->assertSame(0, $statusCode); $this->assertDirectoryExists($scaffoldDirectory.'/vendor'); From 5e1173f105e5225f417dcbd8a4bf438b9128458d Mon Sep 17 00:00:00 2001 From: Adrian Date: Sat, 31 Oct 2020 07:48:32 +0100 Subject: [PATCH 10/12] add fileinfo to make league/flysystem happy --- .github/workflows/tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 6b7b942e..69cdec4e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -59,7 +59,7 @@ jobs: uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php }} - extensions: dom, curl, libxml, mbstring, zip + extensions: dom, curl, libxml, mbstring, zip, fileinfo tools: composer:v2 coverage: none ini-values: memory_limit=512M From d65e494940628c78a90ad3b70ec8e2ee5bfc8986 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Sat, 31 Oct 2020 10:24:07 +0100 Subject: [PATCH 11/12] Re-enable all builds --- .github/workflows/tests.yml | 57 ++++++++++++++++++------------------- 1 file changed, 28 insertions(+), 29 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 69cdec4e..945c2150 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -7,33 +7,33 @@ on: - cron: '0 0 * * *' jobs: -# linux_tests: -# -# runs-on: ubuntu-latest -# strategy: -# fail-fast: true -# matrix: -# php: [7.3, 7.4, 8.0] -# -# name: PHP ${{ matrix.php }} -# -# steps: -# - name: Checkout code -# uses: actions/checkout@v2 -# -# - name: Setup PHP -# uses: shivammathur/setup-php@v2 -# with: -# php-version: ${{ matrix.php }} -# extensions: dom, curl, libxml, mbstring, zip -# tools: composer:v2 -# coverage: none -# -# - name: Install dependencies -# run: composer install --no-interaction --prefer-dist -# -# - name: Execute tests -# run: vendor/bin/phpunit --verbose + linux_tests: + + runs-on: ubuntu-latest + strategy: + fail-fast: true + matrix: + php: [7.3, 7.4, 8.0] + + name: PHP ${{ matrix.php }} + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php }} + extensions: dom, curl, libxml, mbstring, zip, fileinfo + tools: composer:v2 + coverage: none + + - name: Install dependencies + run: composer install --no-interaction --prefer-dist + + - name: Execute tests + run: vendor/bin/phpunit --verbose windows_tests: @@ -41,8 +41,7 @@ jobs: strategy: fail-fast: true matrix: -# php: [7.3, 7.4, 8.0] - php: [8.0] + php: [7.3, 7.4, 8.0] name: PHP ${{ matrix.php }} - Windows From 58e89b112e1ab333e914c5a94c2e6b9d04f43733 Mon Sep 17 00:00:00 2001 From: Dries Vints Date: Sat, 31 Oct 2020 10:33:40 +0100 Subject: [PATCH 12/12] Add ext-fileinfo to dependencies --- composer.json | 1 + 1 file changed, 1 insertion(+) diff --git a/composer.json b/composer.json index 07e490b8..dfc079f3 100644 --- a/composer.json +++ b/composer.json @@ -11,6 +11,7 @@ ], "require": { "php": "^7.3|^8.0", + "ext-fileinfo": "*", "symfony/console": "^4.0|^5.0", "symfony/process": "^4.2|^5.0" },