Skip to content

Commit

Permalink
use makefile in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
Randy Geraads committed Nov 29, 2023
1 parent 7c22b53 commit 652abfe
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 13 deletions.
18 changes: 6 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on: [ push ]

jobs:
build:
runs-on: [ ubuntu-latest ]
runs-on: ubuntu-latest
name: Run CI suite
env:
DATABASE_URL: 'mysql://root:[email protected]:3306/app'
Expand All @@ -22,11 +22,8 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
extensions: mysql
- name: Build the stack
run: make setup

- name: The PHP Security Checker
uses: symfonycorp/security-checker-action@v5
Expand All @@ -44,13 +41,10 @@ jobs:
${{ runner.os }}-composer-
- name: Install dependencies
run: composer install --no-progress --ansi
run: make dependencies

- name: Run cs-fixer
run: vendor/bin/php-cs-fixer fix --dry-run --stop-on-violation --ansi
run: make qa

- name: Run tests
run: bin/phpunit

- name: Run phpstan
run: vendor/bin/phpstan analyse --no-progress --ansi
run: make test
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ifneq ("$(wildcard .docker)","")
endif

test: phpunit ## Run the test suite
qa: phpstan cs lint ## Run the quality assurance suite
qa: validate-composer phpstan cs lint ## Run the quality assurance suite

enable-docker: ## Enable Docker commands
@touch .docker
Expand Down

0 comments on commit 652abfe

Please sign in to comment.