added unit tests

This commit is contained in:
2026-06-04 21:40:59 +02:00
parent d80a8de559
commit 48a619ee4b
64 changed files with 3807 additions and 33 deletions

27
.github/workflows/phpunit.yml vendored Normal file
View File

@ -0,0 +1,27 @@
name: PHPUnit
on:
push:
branches: [main, master]
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
extensions: json, openssl, pdo, pdo_sqlite, zip
coverage: pcov
tools: composer:v2
- name: Install dependencies
run: composer install --no-interaction --prefer-dist
- name: Run tests with coverage floor
run: php tests/check-coverage.php 40