Skip to content
Merged
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
56 changes: 56 additions & 0 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
on:
- push

name: Run Codecov checks

jobs:
code-coverage:
name: Code Coverage

runs-on: ${{ matrix.os }}

strategy:
matrix:
os:
- ubuntu-latest

php:
- "8.2"
- "8.3"
- "8.4"

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: "${{ matrix.php }}"
coverage: pcov
ini-values: assert.exception=1, zend.assertions=1, error_reporting=-1, log_errors_max_len=0, display_errors=On
tools: composer:v2, cs2pr

- name: Determine composer cache directory
run: echo "COMPOSER_CACHE_DIR=$(composer config cache-dir)" >> $GITHUB_ENV

- name: Cache dependencies installed with composer
uses: actions/cache@v4
with:
path: ${{ env.COMPOSER_CACHE_DIR }}
key: php${{ matrix.php }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: |
php${{ matrix.php }}-composer-

- name: Install dependencies with composer
env:
COMPOSER_DEV_MODE: 1
run: composer install --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi

- name: Collect code coverage with PHPUnit
run: vendor/bin/phpunit --colors=always --coverage-clover clover.xml

- name: Send code coverage report to Codecov.io
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
26 changes: 2 additions & 24 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,30 +4,8 @@ on:
pull_request:
push:
branches:
- '[0-9]+.[0-9]+.x'
- 'refs/pull/*'
tags:

jobs:
matrix:
name: Generate job matrix
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.matrix.outputs.matrix }}
steps:
- name: Gather CI configuration
id: matrix
uses: laminas/laminas-ci-matrix-action@v1

qa:
name: QA Checks
needs: [matrix]
runs-on: ${{ matrix.operatingSystem }}
strategy:
fail-fast: false
matrix: ${{ fromJSON(needs.matrix.outputs.matrix) }}
steps:
- name: ${{ matrix.name }}
uses: laminas/laminas-continuous-integration-action@v1
with:
job: ${{ matrix.job }}
ci:
uses: laminas/workflow-continuous-integration/.github/workflows/continuous-integration.yml@1.x
37 changes: 0 additions & 37 deletions .github/workflows/create-project.yml

This file was deleted.

48 changes: 48 additions & 0 deletions .github/workflows/qodana_code_quality.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Qodana
on:
workflow_dispatch:
pull_request:
push:
branches:
- 'main'

jobs:
qodana:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
checks: write
strategy:
matrix:
php-versions: [ '8.2', '8.3', '8.4']
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }} # to check out the actual pull request commit, not the merge commit
fetch-depth: 0 # a full history is required for pull request analysis
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
coverage: pcov
ini-values: assert.exception=1, zend.assertions=1, error_reporting=-1, log_errors_max_len=0, display_errors=On
tools: composer:v2, cs2pr

- name: Determine composer cache directory
run: echo "COMPOSER_CACHE_DIR=$(composer config cache-dir)" >> $GITHUB_ENV

- name: Cache dependencies installed with composer
uses: actions/cache@v4
with:
path: ${{ env.COMPOSER_CACHE_DIR }}
key: php${{ matrix.php }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: |
php${{ matrix.php }}-composer-

- name: Install dependencies with composer
run: composer install --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
- name: 'Qodana Scan'
uses: JetBrains/qodana-action@v2025.1
env:
QODANA_TOKEN: ${{ secrets.QODANA_TOKEN }}
71 changes: 0 additions & 71 deletions .github/workflows/release-on-milestone-closed.yml

This file was deleted.

32 changes: 6 additions & 26 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
"symfony/redis-messenger": "^v7.2.3"
},
"require-dev": {
"laminas/laminas-coding-standard": "^3.0",
"phpunit/phpunit": "^10.5.45",
"psalm/plugin-phpunit": "^0.19.2",
"roave/security-advisories": "dev-master",
Expand All @@ -66,39 +67,18 @@
},
"autoload-dev": {
"psr-4": {
"DotTest\\Mail\\": "test/"
}
},
"scripts": {
"development-disable": "laminas-development-mode disable",
"development-enable": "laminas-development-mode enable",
"development-status": "laminas-development-mode status",
"mezzio": "laminas --ansi",
"check": [
"@cs-check",
"@test"
],
"clear-config-cache": "php bin/clear-config-cache.php",
"enable-codestandard": "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\Plugin::run",
"cs-check": [
"@enable-codestandard",
"phpcs -s"
],
"cs-fix": [
"@enable-codestandard",
"phpcbf"
],
"serve": [
"Composer\\Config::disableProcessTimeout",
"php -S 0.0.0.0:8080 -t public/"
],
"static-analysis": "psalm --stats",
"static-analysis-update-baseline": "psalm --stats --update-baseline",
"cs-check": "phpcs",
"cs-fix": "phpcbf",
"test": "phpunit --colors=always",
"test-coverage": "phpunit --colors=always --coverage-clover clover.xml"
},
"scripts-descriptions": {
"clear-config-cache": "Clears merged config cache. Required for config changes to be applied.",
"static-analysis": "Run static analysis tool Psalm.",
"static-analysis-update-baseline": "Run static analysis tool Psalm and update baseline."
"test-coverage": "phpunit --colors=always --coverage-clover clover.xml",
"static-analysis": "psalm --shepherd --stats"
}
}
16 changes: 11 additions & 5 deletions config/autoload/cli.global.php
Original file line number Diff line number Diff line change
@@ -1,20 +1,26 @@
<?php

declare(strict_types=1);

use Dot\Cli\FileLockerInterface;
use Queue\Swoole\Command\StartCommand;
use Queue\Swoole\Command\StopCommand;
use Symfony\Component\Messenger\Command\ConsumeMessagesCommand;
use Symfony\Component\Messenger\Command\DebugCommand;

return [
'dot_cli' => [
'version' => '1.0.0',
'name' => 'DotKernel CLI',
'commands' => [
"swoole:start" => \Queue\Swoole\Command\StartCommand::class,
"swoole:stop" => \Queue\Swoole\Command\StopCommand::class,
"messenger:start" => \Symfony\Component\Messenger\Command\ConsumeMessagesCommand::class,
"messenger:debug" => \Symfony\Component\Messenger\Command\DebugCommand::class
"swoole:start" => StartCommand::class,
"swoole:stop" => StopCommand::class,
"messenger:start" => ConsumeMessagesCommand::class,
"messenger:debug" => DebugCommand::class,
],
],
FileLockerInterface::class => [
'enabled' => false,
'dirPath' => getcwd() . '/data/lock',
],
];
];
3 changes: 0 additions & 3 deletions config/pipeline.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
// - $app->pipe('/docs', $apiDocMiddleware);
// - $app->pipe('/files', $filesMiddleware);


// The following handle routing failures for common conditions:
// - HEAD request but no routes answer that method
// - OPTIONS request but no routes answer that method
Expand All @@ -53,9 +52,7 @@

// Register the dispatch middleware in the middleware pipeline


// At this point, if no Response is returned by any middleware, the
// NotFoundHandler kicks in; alternately, you can provide other fallback
// middleware to execute.

};
Loading
Loading