From 35a7a12106190112cfb49d5eb4c194a2bb3ca016 Mon Sep 17 00:00:00 2001 From: Gintautas Miselis Date: Fri, 18 Dec 2020 21:17:31 +0200 Subject: [PATCH] Use Github Actions --- .github/workflows/main.yml | 29 +++++++++++++++++++++++++++++ .travis.yml | 19 ------------------- Readme.md | 4 ++-- 3 files changed, 31 insertions(+), 21 deletions(-) create mode 100644 .github/workflows/main.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..9a0040e --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,29 @@ +name: CI + +on: [push, pull_request] + +jobs: + tests: + runs-on: ubuntu-latest + + strategy: + matrix: + php: [7.1, 7.2, 7.3, 7.4, 8.0] + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php }} + + - name: Validate composer.json + run: composer validate + + - name: Install dependencies + run: composer update --prefer-source + + - name: Run test suite + run: php vendor/bin/phpunit diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 5dc9f55..0000000 --- a/.travis.yml +++ /dev/null @@ -1,19 +0,0 @@ -language: php - -php: - - 7.1 - - 7.2 - - 7.3 - - 7.4 - -cache: - directories: - - vendor - - $HOME/.composer/cache - -sudo: false - -before_install: - - composer update --prefer-source - -script: vendor/bin/phpunit \ No newline at end of file diff --git a/Readme.md b/Readme.md index 9f51c4d..9f0c9b6 100644 --- a/Readme.md +++ b/Readme.md @@ -2,7 +2,7 @@ Handle exceptions inside a test without a stop! Works with PHPUnit and Codeception. -[![Build Status](https://travis-ci.org/Codeception/AssertThrows.svg?branch=master)](https://travis-ci.org/Codeception/AssertThrows) +![Build Status](https://github.com/Codeception/AssertThrows/workflows/CI/badge.svg) ## Installation @@ -57,4 +57,4 @@ $this->assertThrowsWithMessage( ); ``` -### License MIT \ No newline at end of file +### License MIT