From c6f3bab8ab87a567b0a9b72a880f56568e5fb5e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20L=C3=BCck?= Date: Fri, 22 Jan 2021 19:51:22 +0100 Subject: [PATCH] Use GitHub actions for continuous integration (CI) Bye bye Travis CI, you've served us well. --- .gitattributes | 2 +- .github/workflows/ci.yml | 42 ++++++++++++++++++++++++++++++++++++++++ .travis.yml | 26 ------------------------- README.md | 4 ++-- 4 files changed, 45 insertions(+), 29 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .travis.yml diff --git a/.gitattributes b/.gitattributes index 982c460d..4a09071e 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,5 +1,5 @@ /.gitattributes export-ignore +/.github/ export-ignore /.gitignore export-ignore -/.travis.yml export-ignore /phpunit.xml.dist export-ignore /tests export-ignore diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..4be7ca28 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,42 @@ +name: CI + +on: + push: + pull_request: + +jobs: + PHPUnit: + name: PHPUnit (PHP ${{ matrix.php }}) + runs-on: ubuntu-18.04 + strategy: + matrix: + php: + - 7.4 + - 7.3 + - 7.2 + - 7.1 + - 7.0 + - 5.6 + - 5.5 + - 5.4 + - 5.3 + steps: + - uses: actions/checkout@v2 + - uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php }} + coverage: xdebug + - run: composer install + - run: vendor/bin/phpunit --coverage-text --exclude-group internet + + PHPUnit-hhvm: + name: PHPUnit (HHVM) + runs-on: ubuntu-18.04 + continue-on-error: true + steps: + - uses: actions/checkout@v2 + - uses: azjezz/setup-hhvm@v1 + with: + version: lts-3.30 + - run: hhvm $(which composer) require phpunit/phpunit:^5 --dev # requires legacy phpunit + - run: hhvm vendor/bin/phpunit --exclude-group internet diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index bc648517..00000000 --- a/.travis.yml +++ /dev/null @@ -1,26 +0,0 @@ -language: php - -# lock distro so new future defaults will not break the build -dist: trusty - -matrix: - include: - - php: 5.3 - dist: precise - - php: 5.4 - - php: 5.5 - - php: 5.6 - - php: 7.0 - - php: 7.1 - - php: 7.2 - - php: 7.3 - - php: 7.4 - - php: hhvm-3.18 - allow_failures: - - php: hhvm-3.18 - -install: - - composer install --no-interaction - -script: - - php vendor/bin/phpunit --coverage-text --exclude-group internet diff --git a/README.md b/README.md index 6c4e13e3..ba93429a 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@
- Build Status + Build Status

@@ -265,7 +265,7 @@ $ php vendor/bin/phpunit The test suite also contains a number of functional integration tests that rely on a stable internet connection. Due to the vast number of integration tests, -these are skipped by default on Travis CI. If you also do not want to run these, +these are skipped by default during CI runs. If you also do not want to run these, they can simply be skipped like this: ```bash