From 27627e3c3d1a4e851f7a09d4a4e400b3a5f5b7a4 Mon Sep 17 00:00:00 2001 From: Aydin Hassan Date: Thu, 22 Oct 2026 13:54:27 +0200 Subject: [PATCH] Replace Travis with GitHub Actions Test the lowest and highest supported PHP on push to 0.8 and on PRs, with a job timeout, composer cache and stop-on-error. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/tests.yml | 36 ++++++++++++++++++++++++++++++++++++ .travis.yml | 23 ----------------------- 2 files changed, 36 insertions(+), 23 deletions(-) create mode 100644 .github/workflows/tests.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..4b65b7b --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,36 @@ +name: Tests + +on: + push: + branches: [0.8] + pull_request: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + tests: + runs-on: ubuntu-latest + timeout-minutes: 10 + strategy: + matrix: + # lowest and highest supported PHP only, to keep CI cheap + php: ['7.4', '8.3'] + steps: + - uses: actions/checkout@v4 + + - uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php }} + coverage: none + + - uses: actions/cache@v4 + with: + path: ~/.cache/composer + key: composer-${{ matrix.php }}-${{ hashFiles('composer.json') }} + restore-keys: composer-${{ matrix.php }}- + + - run: composer update --no-interaction --no-progress --prefer-dist + + - run: vendor/bin/phpunit --stop-on-error diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 20fe0ad..0000000 --- a/.travis.yml +++ /dev/null @@ -1,23 +0,0 @@ -language: php -php: - - '5.5' - - '5.6' - - '7.0' - - hhvm - - nightly - -matrix: - fast_finish: true - allow_failures: - - php: hhvm - - php: nightly - -install: - - composer install - -notifications: - email: - on_success: never - on_failure: always - webhooks: - urls: http://keylighter.kadet.net/travis-hook