From 83e3f39b39d106638a0ac4f61fc32b373bacae75 Mon Sep 17 00:00:00 2001 From: "Barry vd. Heuvel" Date: Thu, 17 Jul 2025 08:02:25 +0200 Subject: [PATCH] Fix tests on windows (#1720) * Update run-tests.yml * Update snapshot * Simplify matrix --- .github/workflows/run-tests.yml | 9 +++++++-- .../AdvancedCasts/__snapshots__/Test__test__1.php | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index d4f84f9..6094371 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -20,13 +20,18 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-22.04, windows-2019] + os: [ubuntu-latest] php: [8.4, 8.3, 8.2] laravel: [~11.15, 12.x] stability: [prefer-lowest, prefer-stable] + include: + - os: windows-latest + php: 8.3 + laravel: 12.x + stability: prefer-stable steps: - name: Set git to use LF - if: ${{ matrix.os == 'windows-2019' }} + if: ${{ matrix.os == 'windows-latest' }} run: | git config --global core.autocrlf false git config --global core.eol lf diff --git a/tests/Console/ModelsCommand/AdvancedCasts/__snapshots__/Test__test__1.php b/tests/Console/ModelsCommand/AdvancedCasts/__snapshots__/Test__test__1.php index 8e90196..a1ea211 100644 --- a/tests/Console/ModelsCommand/AdvancedCasts/__snapshots__/Test__test__1.php +++ b/tests/Console/ModelsCommand/AdvancedCasts/__snapshots__/Test__test__1.php @@ -74,7 +74,7 @@ class AdvancedCast extends Model 'cast_to_as_collection' => AsCollection::class, 'cast_to_as_collection_of' => AsCollection::class . ':,' . AdvancedCastMap::class, // since 12.10 'cast_to_as_collection_using' => AsCollection::using(AdvancedCastCollection::class), - 'cast_to_as_collection_using_and_map' => AsCollection::class . ':' . AdvancedCastCollection::class. ',' . AdvancedCastMap::class, // since 12.10 + 'cast_to_as_collection_using_and_map' => AsCollection::class . ':' . AdvancedCastCollection::class . ',' . AdvancedCastMap::class, // since 12.10 'cast_to_as_enum_collection' => AsEnumCollection::class, 'cast_to_as_enum_collection_of' => AsEnumCollection::of(AdvancedCastEnum::class), 'cast_to_as_array_object' => AsArrayObject::class,