Skip to content

Commit

Permalink
Github actions test
Browse files Browse the repository at this point in the history
  • Loading branch information
danielholmes committed Apr 9, 2020
1 parent f224294 commit f424b85
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 1 deletion.
50 changes: 50 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Test

on:
push:
branches: master

jobs:
deploy:
name: Test on PHP ${{ matrix.php_version }}
strategy:
matrix:
php_version:
- 7.1
- 7.2
- 7.3
- 7.4

runs-on: ubuntu-18.04

steps:
- uses: actions/checkout@v2
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php_version }}
- name: "PHP deps"
run: |
printf "\n" | pecl install imagick
sudo apt-get install -y pngquant
composer install
- name: "Install Yarn"
run: |
sudo apt-key adv --fetch-keys http://dl.yarnpkg.com/debian/pubkey.gpg
echo "deb http://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt-get update -qq
sudo apt-get install -y -qq yarn
yarn install
- name: "Setup MySQL"
run: sudo apt install mysql
- name: "Setup BGA Project"
run: cp bgaproject.yml.travis.dist bgaproject.yml
- name: Check JS
run: yarn lint:check
- name: Run tests
run: |
composer compile-images > /dev/null
composer clean
composer build
composer bga-validate
composer check-styles
composer test
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ services:
- mysql

php:
- 7.0.8
- 7.1
- 7.2
- 7.3
- 7.4

cache:
yarn: true
Expand Down

0 comments on commit f424b85

Please sign in to comment.