From bf9e8332169760a9b0ca194a8884a4909e5bbb36 Mon Sep 17 00:00:00 2001 From: peter279k Date: Thu, 23 Jul 2020 13:30:53 +0800 Subject: [PATCH] Resolves issue #23 --- .github/workflows/build.yml | 41 +++++++++++++++++++++++++++++++++++++ .travis.yml | 19 ----------------- 2 files changed, 41 insertions(+), 19 deletions(-) create mode 100644 .github/workflows/build.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..d0cc5ee --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,41 @@ +name: build + +on: [push, pull_request] + +jobs: + run: + runs-on: ${{ matrix.operating-system }} + strategy: + matrix: + operating-system: [ubuntu-latest] + php-versions: ['7.2', '7.3', '7.4'] + name: PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }} + + steps: + - name: Checkout + uses: actions/checkout@v1 + + - name: Setup PHP + uses: shivammathur/setup-php@v1 + with: + php-version: ${{ matrix.php-versions }} + extensions: mbstring, pdo, pdo_mysql, intl, zip + coverage: none + + - name: Check PHP Version + run: php -v + + - name: Check Composer Version + run: composer -V + + - name: Check PHP Extensions + run: php -m + + - name: Validate composer.json and composer.lock + run: composer validate + + - name: Install dependencies + run: composer install --prefer-dist --no-progress --no-suggest + + - name: Run test suite + run: composer check-all diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 0b411d7..0000000 --- a/.travis.yml +++ /dev/null @@ -1,19 +0,0 @@ -language: php - -php: - - 7.2 - - 7.3 - -dist: xenial - -cache: - directories: - - $HOME/.composer/cache - -before_script: - - composer self-update - - composer install --no-interaction --prefer-dist --no-progress - - cd $TRAVIS_BUILD_DIR - -script: - - composer check-all