Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,40 @@ jobs:
if: always()
run: docker compose down -v

pest:
name: Pest (PHP ${{ matrix.php }})
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
php: ["8.5"]

steps:
- name: Checkout
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
with:
fetch-depth: 2

- name: Setup PHP, with composer and extensions
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
with:
php-version: ${{ matrix.php }}
tools: phpunit
extensions: mbstring, xml, ctype, iconv, intl, pdo_sqlite
coverage: xdebug

- name: Install Composer dependencies
uses: ramsey/composer-install@65e4f84970763564f46a70b8a54b90d033b3bdda # 4.0.0

- name: Install Pest
run: |
composer config allow-plugins.pestphp/pest-plugin true
composer require --dev pestphp/pest:^5.0 --no-interaction

- name: Run Pest
run: composer run pest -- --no-coverage

code-quality:
name: Check ${{ matrix.tool }} (PHP ${{ matrix.php }})
runs-on: ubuntu-latest
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
"codestyle": "php-cs-fixer fix",
"coverage": "phpunit -c tests/phpunit-coverage.dist.xml --coverage-html=\".phpunit.cache/code-coverage\"",
"phpstan": "phpstan analyze --memory-limit 512M --configuration .phpstan.neon",
"infection": "infection --threads=4 --min-covered-msi=0",
"phpunit": "phpunit -c phpunit.dist.xml",
"rectify": [
"@rector",
Expand Down
14 changes: 13 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ services:
- ./:/work
working_dir: /work

php:
php74:
build: # Info to build the Docker image
context: ./.docker # Specify where the Dockerfile is located (e.g. in the root directory of the project)
dockerfile: PHP74-Dockerfile # Specify the name of the Dockerfile
Expand All @@ -25,6 +25,18 @@ services:
volumes:
- ./:/var/www/project/ # Location of the project for php-fpm. Note this should be the same for NGINX.*

php:
build:
context: ./.docker
dockerfile: PHP85-Dockerfile
ports:
- 8112:80
depends_on:
- init-volumes
- redmine-dev
volumes:
- ./:/var/www/project/

redmine-dev:
image: redmine:7.0.0
user: "33:33"
Expand Down
10 changes: 10 additions & 0 deletions infection.json.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"source": {
"directories": [
"src/"
]
},
"logs": {
"text": ".phpunit.cache/infection.log"
}
}
7 changes: 7 additions & 0 deletions pest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

declare(strict_types=1);

require_once __DIR__ . '/vendor/autoload.php';

uses()->in('tests/Pest');
1 change: 0 additions & 1 deletion phpunit.dist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
displayDetailsOnIncompleteTests="true"
displayDetailsOnSkippedTests="true"
displayDetailsOnTestsThatTriggerDeprecations="true"
displayDetailsOnPhpunitDeprecations="true"
displayDetailsOnTestsThatTriggerErrors="true"
displayDetailsOnTestsThatTriggerNotices="true"
displayDetailsOnTestsThatTriggerWarnings="true"
Expand Down
Loading