chore(ci): new test workflow

This commit is contained in:
Baoshuo Ren 2022-03-17 11:11:07 +08:00
parent 2193962238
commit a03a5063d7
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A
2 changed files with 43 additions and 12 deletions

View File

@ -1,12 +0,0 @@
on: [push, pull_request]
name: Main
jobs:
php-cs-fixer:
name: PHP-CS-Fixer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: PHP-CS-Fixer
uses: docker://oskarstark/php-cs-fixer-ga
with:
args: --config=./web/.php-cs-fixer.php --diff --dry-run

43
.github/workflows/test.yml vendored Normal file
View File

@ -0,0 +1,43 @@
name: Lint & Test
on:
- push
- pull_request
jobs:
php-cs-fixer:
name: PHP-CS-Fixer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: PHP-CS-Fixer
uses: docker://oskarstark/php-cs-fixer-ga
with:
args: --config=./web/.php-cs-fixer.php --diff --dry-run
docker-db:
name: Build Docker Image (uoj-db)
needs: php-cs-fixer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build Docker Image (uoj-db)
run: docker-compose build uoj-db
docker-judger:
name: Build Docker Image (uoj-judger)
needs: php-cs-fixer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build Docker Image
run: docker-compose build uoj-judger
docker-web:
name: Build Docker Image (uoj-web)
needs: php-cs-fixer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build Docker Image (uoj-web)
run: docker-compose build uoj-web