28 lines
679 B
YAML
28 lines
679 B
YAML
name: Tests
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
branches: [ master ]
|
|
|
|
jobs:
|
|
tests:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: composer:2
|
|
|
|
steps:
|
|
- name: Checkout
|
|
run: |
|
|
git init .
|
|
git remote add origin "https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@$(echo "${{ github.server_url }}" | sed -E 's|https?://||')/${{ github.repository }}.git"
|
|
git fetch --depth 1 origin "${{ github.ref }}"
|
|
git checkout FETCH_HEAD
|
|
|
|
- name: Install Composer dependencies
|
|
run: composer install --no-interaction --prefer-dist
|
|
|
|
- name: Run PHPUnit
|
|
run: vendor/bin/phpunit
|