Skip to content

Honour the discount stop flag in the apply loop #4291

Honour the discount stop flag in the apply loop

Honour the discount stop flag in the apply loop #4291

Workflow file for this run

name: Tests
on:
pull_request:
paths-ignore:
- "**/*.md"
push:
branches: [1.x]
schedule:
# Daily full-matrix sweep to catch dependency drift on the lower combos.
- cron: "0 6 * * *"
concurrency:
group: tests-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
run-tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# PRs run a slimmed matrix; push and the schedule run the full one.
php: ${{ fromJSON(github.event_name == 'pull_request' && '["8.4"]' || '["8.3","8.4"]') }}
laravel: ["12.*", "13.*"]
dependency-version: [prefer-stable]
testsuite: [core, admin, shipping, stripe, search]
extend-models: ${{ fromJSON(github.event_name == 'pull_request' && '["false"]' || '["true","false"]') }}
include:
- laravel: 12.*
testbench: 10.*
- laravel: 13.*
testbench: 11.*
name: ${{ matrix.testsuite }} - PHP ${{ matrix.php }} - L${{ matrix.laravel }} ${{ matrix.dependency-version == 'prefer-lowest' && '↓' || '↑' }} ${{ matrix.extend-models == 'true' && 'E' || '' }}
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring, pdo, pdo_sqlite
tools: composer:v2
coverage: none
- name: Pin Laravel + Testbench versions
run: |
composer require "laravel/framework:${{ matrix.laravel }}" --no-update --no-interaction
composer require "orchestra/testbench:${{ matrix.testbench }}" --dev --no-update --no-interaction
- name: Install Composer dependencies
uses: ramsey/composer-install@v4
with:
composer-options: "--prefer-dist ${{ matrix.dependency-version == 'prefer-lowest' && '--prefer-lowest' || '' }}"
custom-cache-key: composer-p${{ matrix.php }}-l${{ matrix.laravel }}-${{ matrix.dependency-version }}-${{ hashFiles('composer.json') }}
- name: Execute tests
env:
APP_ENV: testing
DB_CONNECTION: testing
DB_DATABASE: ":memory:"
LUNAR_TESTING_REPLACE_MODELS: ${{ matrix.extend-models }}
run: ./vendor/bin/pest --testsuite ${{ matrix.testsuite }} --parallel