From 071e76f78eedbe4ca9f7b82bd660292d2e755893 Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 17:33:11 +0330 Subject: [PATCH 1/8] chore: add larastan as dev dependency --- AGENTS.md | 10 ++- composer.json | 1 + composer.lock | 197 +++++++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 206 insertions(+), 2 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 07492a6..ae038be 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -13,6 +13,7 @@ This application is a Laravel application and its main Laravel ecosystems packag - laravel/framework (LARAVEL) - v13 - laravel/prompts (PROMPTS) - v0 - laravel/sanctum (SANCTUM) - v4 +- larastan/larastan (LARASTAN) - v3 - laravel/boost (BOOST) - v2 - laravel/mcp (MCP) - v0 - laravel/pail (PAIL) - v1 @@ -97,7 +98,7 @@ This project has domain-specific skills available in `**/skills/**`. You MUST ac - Always use curly braces for control structures, even for single-line bodies. - Use PHP 8 constructor property promotion: `public function __construct(public GitHub $github) { }`. Do not leave empty zero-parameter `__construct()` methods unless the constructor is private. - Use explicit return type declarations and type hints for all method parameters: `function isAccessible(User $user, ?string $path = null): bool` -- Use TitleCase for Enum keys: `FavoritePerson`, `BestLake`, `Monthly`. +- Follow existing application Enum naming conventions. - Prefer PHPDoc blocks over inline comments. Only add inline comments for exceptionally complex logic. - Use array shape type definitions in PHPDoc blocks. @@ -107,6 +108,13 @@ This project has domain-specific skills available in `**/skills/**`. You MUST ac - Laravel can be deployed using [Laravel Cloud](https://cloud.laravel.com/), which is the fastest way to deploy and scale production Laravel applications. +=== tests rules === + +# Test Enforcement + +- Every change must be programmatically tested. Write a new test or update an existing test, then run the affected tests to make sure they pass. +- Run the minimum number of tests needed to ensure code quality and speed. Use `php artisan test --compact` with a specific filename or filter. + === laravel/core rules === # Do Things the Laravel Way diff --git a/composer.json b/composer.json index c62f73d..91b2df8 100644 --- a/composer.json +++ b/composer.json @@ -19,6 +19,7 @@ }, "require-dev": { "fakerphp/faker": "^1.23", + "larastan/larastan": "^3.10", "laravel/boost": "^2.2", "laravel/pail": "^1.2.5", "laravel/pao": "^1.0.6", diff --git a/composer.lock b/composer.lock index 84ccb20..e9d4828 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "729a78bb11b6350b3fcfcabb236d3bd5", + "content-hash": "4749eaab7635b7251521126062f586f2", "packages": [ { "name": "brick/math", @@ -6700,6 +6700,47 @@ }, "time": "2025-04-30T06:54:44+00:00" }, + { + "name": "iamcal/sql-parser", + "version": "v0.7", + "source": { + "type": "git", + "url": "https://github.com/iamcal/SQLParser.git", + "reference": "610392f38de49a44dab08dc1659960a29874c4b8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/iamcal/SQLParser/zipball/610392f38de49a44dab08dc1659960a29874c4b8", + "reference": "610392f38de49a44dab08dc1659960a29874c4b8", + "shasum": "" + }, + "require-dev": { + "php-coveralls/php-coveralls": "^1.0", + "phpunit/phpunit": "^5|^6|^7|^8|^9" + }, + "type": "library", + "autoload": { + "psr-4": { + "iamcal\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Cal Henderson", + "email": "cal@iamcal.com" + } + ], + "description": "MySQL schema parser", + "support": { + "issues": "https://github.com/iamcal/SQLParser/issues", + "source": "https://github.com/iamcal/SQLParser/tree/v0.7" + }, + "time": "2026-01-28T22:20:33+00:00" + }, { "name": "jean85/pretty-package-versions", "version": "2.1.1", @@ -6760,6 +6801,96 @@ }, "time": "2025-03-19T14:43:43+00:00" }, + { + "name": "larastan/larastan", + "version": "v3.10.0", + "source": { + "type": "git", + "url": "https://github.com/larastan/larastan.git", + "reference": "2970f83398154178a739609c244577267c7ee8eb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/larastan/larastan/zipball/2970f83398154178a739609c244577267c7ee8eb", + "reference": "2970f83398154178a739609c244577267c7ee8eb", + "shasum": "" + }, + "require": { + "ext-json": "*", + "iamcal/sql-parser": "^0.7.0", + "illuminate/console": "^11.44.2 || ^12.4.1 || ^13", + "illuminate/container": "^11.44.2 || ^12.4.1 || ^13", + "illuminate/contracts": "^11.44.2 || ^12.4.1 || ^13", + "illuminate/database": "^11.44.2 || ^12.4.1 || ^13", + "illuminate/http": "^11.44.2 || ^12.4.1 || ^13", + "illuminate/pipeline": "^11.44.2 || ^12.4.1 || ^13", + "illuminate/support": "^11.44.2 || ^12.4.1 || ^13", + "php": "^8.2", + "phpstan/phpstan": "^2.2.0" + }, + "require-dev": { + "doctrine/coding-standard": "^14", + "laravel/framework": "^11.44.2 || ^12.7.2 || ^13", + "mockery/mockery": "^1.6.12", + "nikic/php-parser": "^5.4", + "orchestra/canvas": "^v9.2.2 || ^10.0.1 || ^11", + "orchestra/testbench-core": "^9.12.0 || ^10.1 || ^11", + "phpstan/phpstan-deprecation-rules": "^2.0.1", + "phpunit/phpunit": "^10.5.35 || ^11.5.15 || ^12.5.8 || ^13.1.8" + }, + "suggest": { + "orchestra/testbench": "Using Larastan for analysing a package needs Testbench", + "phpmyadmin/sql-parser": "Install to enable Larastan's optional phpMyAdmin-based SQL parser automatically" + }, + "type": "phpstan-extension", + "extra": { + "phpstan": { + "includes": [ + "extension.neon" + ] + }, + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "psr-4": { + "Larastan\\Larastan\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Can Vural", + "email": "can9119@gmail.com" + } + ], + "description": "Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel", + "keywords": [ + "PHPStan", + "code analyse", + "code analysis", + "larastan", + "laravel", + "package", + "php", + "static analysis" + ], + "support": { + "issues": "https://github.com/larastan/larastan/issues", + "source": "https://github.com/larastan/larastan/tree/v3.10.0" + }, + "funding": [ + { + "url": "https://github.com/canvural", + "type": "github" + } + ], + "time": "2026-05-28T08:00:58+00:00" + }, { "name": "laravel/agent-detector", "version": "v2.0.2", @@ -8209,6 +8340,70 @@ }, "time": "2026-01-06T21:53:42+00:00" }, + { + "name": "phpstan/phpstan", + "version": "2.2.9", + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/13d6b4f347bad222da436580c8304fa6f83e6bd0", + "reference": "13d6b4f347bad222da436580c8304fa6f83e6bd0", + "shasum": "" + }, + "require": { + "php": "^7.4|^8.0" + }, + "conflict": { + "phpstan/phpstan-shim": "*" + }, + "bin": [ + "phpstan", + "phpstan.phar" + ], + "type": "library", + "autoload": { + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ondřej Mirtes" + }, + { + "name": "Markus Staab" + }, + { + "name": "Vincent Langlet" + } + ], + "description": "PHPStan - PHP Static Analysis Tool", + "keywords": [ + "dev", + "static analysis" + ], + "support": { + "docs": "https://phpstan.org/user-guide/getting-started", + "forum": "https://github.com/phpstan/phpstan/discussions", + "issues": "https://github.com/phpstan/phpstan/issues", + "security": "https://github.com/phpstan/phpstan/security/policy", + "source": "https://github.com/phpstan/phpstan-src" + }, + "funding": [ + { + "url": "https://github.com/ondrejmirtes", + "type": "github" + }, + { + "url": "https://github.com/phpstan", + "type": "github" + } + ], + "time": "2026-08-22T07:38:16+00:00" + }, { "name": "phpunit/php-code-coverage", "version": "14.2.4", From a9f3d300e6eedfe56b940c14416a1f9076dd9711 Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 17:41:54 +0330 Subject: [PATCH 2/8] chore: configure phpstan at level 5 --- .gitignore | 1 + phpstan.neon | 8 ++++++++ 2 files changed, 9 insertions(+) create mode 100644 phpstan.neon diff --git a/.gitignore b/.gitignore index 7be55e2..465c609 100644 --- a/.gitignore +++ b/.gitignore @@ -25,3 +25,4 @@ _ide_helper.php Homestead.json Homestead.yaml Thumbs.db +/build/phpstan \ No newline at end of file diff --git a/phpstan.neon b/phpstan.neon new file mode 100644 index 0000000..5613b4f --- /dev/null +++ b/phpstan.neon @@ -0,0 +1,8 @@ +includes: + - vendor/larastan/larastan/extension.neon + +parameters: + paths: + - app + level: 5 + tmpDir: build/phpstan \ No newline at end of file From 0ba3506a9dd4729083ae055f4a6a1edbb084e97e Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 18:59:59 +0330 Subject: [PATCH 3/8] Revert "chore: configure phpstan at level 5" This reverts commit a9f3d300e6eedfe56b940c14416a1f9076dd9711. --- .gitignore | 1 - phpstan.neon | 8 -------- 2 files changed, 9 deletions(-) delete mode 100644 phpstan.neon diff --git a/.gitignore b/.gitignore index 465c609..7be55e2 100644 --- a/.gitignore +++ b/.gitignore @@ -25,4 +25,3 @@ _ide_helper.php Homestead.json Homestead.yaml Thumbs.db -/build/phpstan \ No newline at end of file diff --git a/phpstan.neon b/phpstan.neon deleted file mode 100644 index 5613b4f..0000000 --- a/phpstan.neon +++ /dev/null @@ -1,8 +0,0 @@ -includes: - - vendor/larastan/larastan/extension.neon - -parameters: - paths: - - app - level: 5 - tmpDir: build/phpstan \ No newline at end of file From 9896c24c18e9e8f3a462b4f478cd012fd7214e0a Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 19:00:05 +0330 Subject: [PATCH 4/8] Revert "chore: add larastan as dev dependency" This reverts commit 071e76f78eedbe4ca9f7b82bd660292d2e755893. --- AGENTS.md | 10 +-- composer.json | 1 - composer.lock | 197 +------------------------------------------------- 3 files changed, 2 insertions(+), 206 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index ae038be..07492a6 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -13,7 +13,6 @@ This application is a Laravel application and its main Laravel ecosystems packag - laravel/framework (LARAVEL) - v13 - laravel/prompts (PROMPTS) - v0 - laravel/sanctum (SANCTUM) - v4 -- larastan/larastan (LARASTAN) - v3 - laravel/boost (BOOST) - v2 - laravel/mcp (MCP) - v0 - laravel/pail (PAIL) - v1 @@ -98,7 +97,7 @@ This project has domain-specific skills available in `**/skills/**`. You MUST ac - Always use curly braces for control structures, even for single-line bodies. - Use PHP 8 constructor property promotion: `public function __construct(public GitHub $github) { }`. Do not leave empty zero-parameter `__construct()` methods unless the constructor is private. - Use explicit return type declarations and type hints for all method parameters: `function isAccessible(User $user, ?string $path = null): bool` -- Follow existing application Enum naming conventions. +- Use TitleCase for Enum keys: `FavoritePerson`, `BestLake`, `Monthly`. - Prefer PHPDoc blocks over inline comments. Only add inline comments for exceptionally complex logic. - Use array shape type definitions in PHPDoc blocks. @@ -108,13 +107,6 @@ This project has domain-specific skills available in `**/skills/**`. You MUST ac - Laravel can be deployed using [Laravel Cloud](https://cloud.laravel.com/), which is the fastest way to deploy and scale production Laravel applications. -=== tests rules === - -# Test Enforcement - -- Every change must be programmatically tested. Write a new test or update an existing test, then run the affected tests to make sure they pass. -- Run the minimum number of tests needed to ensure code quality and speed. Use `php artisan test --compact` with a specific filename or filter. - === laravel/core rules === # Do Things the Laravel Way diff --git a/composer.json b/composer.json index 91b2df8..c62f73d 100644 --- a/composer.json +++ b/composer.json @@ -19,7 +19,6 @@ }, "require-dev": { "fakerphp/faker": "^1.23", - "larastan/larastan": "^3.10", "laravel/boost": "^2.2", "laravel/pail": "^1.2.5", "laravel/pao": "^1.0.6", diff --git a/composer.lock b/composer.lock index e9d4828..84ccb20 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "4749eaab7635b7251521126062f586f2", + "content-hash": "729a78bb11b6350b3fcfcabb236d3bd5", "packages": [ { "name": "brick/math", @@ -6700,47 +6700,6 @@ }, "time": "2025-04-30T06:54:44+00:00" }, - { - "name": "iamcal/sql-parser", - "version": "v0.7", - "source": { - "type": "git", - "url": "https://github.com/iamcal/SQLParser.git", - "reference": "610392f38de49a44dab08dc1659960a29874c4b8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/iamcal/SQLParser/zipball/610392f38de49a44dab08dc1659960a29874c4b8", - "reference": "610392f38de49a44dab08dc1659960a29874c4b8", - "shasum": "" - }, - "require-dev": { - "php-coveralls/php-coveralls": "^1.0", - "phpunit/phpunit": "^5|^6|^7|^8|^9" - }, - "type": "library", - "autoload": { - "psr-4": { - "iamcal\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Cal Henderson", - "email": "cal@iamcal.com" - } - ], - "description": "MySQL schema parser", - "support": { - "issues": "https://github.com/iamcal/SQLParser/issues", - "source": "https://github.com/iamcal/SQLParser/tree/v0.7" - }, - "time": "2026-01-28T22:20:33+00:00" - }, { "name": "jean85/pretty-package-versions", "version": "2.1.1", @@ -6801,96 +6760,6 @@ }, "time": "2025-03-19T14:43:43+00:00" }, - { - "name": "larastan/larastan", - "version": "v3.10.0", - "source": { - "type": "git", - "url": "https://github.com/larastan/larastan.git", - "reference": "2970f83398154178a739609c244577267c7ee8eb" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/larastan/larastan/zipball/2970f83398154178a739609c244577267c7ee8eb", - "reference": "2970f83398154178a739609c244577267c7ee8eb", - "shasum": "" - }, - "require": { - "ext-json": "*", - "iamcal/sql-parser": "^0.7.0", - "illuminate/console": "^11.44.2 || ^12.4.1 || ^13", - "illuminate/container": "^11.44.2 || ^12.4.1 || ^13", - "illuminate/contracts": "^11.44.2 || ^12.4.1 || ^13", - "illuminate/database": "^11.44.2 || ^12.4.1 || ^13", - "illuminate/http": "^11.44.2 || ^12.4.1 || ^13", - "illuminate/pipeline": "^11.44.2 || ^12.4.1 || ^13", - "illuminate/support": "^11.44.2 || ^12.4.1 || ^13", - "php": "^8.2", - "phpstan/phpstan": "^2.2.0" - }, - "require-dev": { - "doctrine/coding-standard": "^14", - "laravel/framework": "^11.44.2 || ^12.7.2 || ^13", - "mockery/mockery": "^1.6.12", - "nikic/php-parser": "^5.4", - "orchestra/canvas": "^v9.2.2 || ^10.0.1 || ^11", - "orchestra/testbench-core": "^9.12.0 || ^10.1 || ^11", - "phpstan/phpstan-deprecation-rules": "^2.0.1", - "phpunit/phpunit": "^10.5.35 || ^11.5.15 || ^12.5.8 || ^13.1.8" - }, - "suggest": { - "orchestra/testbench": "Using Larastan for analysing a package needs Testbench", - "phpmyadmin/sql-parser": "Install to enable Larastan's optional phpMyAdmin-based SQL parser automatically" - }, - "type": "phpstan-extension", - "extra": { - "phpstan": { - "includes": [ - "extension.neon" - ] - }, - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "psr-4": { - "Larastan\\Larastan\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Can Vural", - "email": "can9119@gmail.com" - } - ], - "description": "Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel", - "keywords": [ - "PHPStan", - "code analyse", - "code analysis", - "larastan", - "laravel", - "package", - "php", - "static analysis" - ], - "support": { - "issues": "https://github.com/larastan/larastan/issues", - "source": "https://github.com/larastan/larastan/tree/v3.10.0" - }, - "funding": [ - { - "url": "https://github.com/canvural", - "type": "github" - } - ], - "time": "2026-05-28T08:00:58+00:00" - }, { "name": "laravel/agent-detector", "version": "v2.0.2", @@ -8340,70 +8209,6 @@ }, "time": "2026-01-06T21:53:42+00:00" }, - { - "name": "phpstan/phpstan", - "version": "2.2.9", - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpstan/zipball/13d6b4f347bad222da436580c8304fa6f83e6bd0", - "reference": "13d6b4f347bad222da436580c8304fa6f83e6bd0", - "shasum": "" - }, - "require": { - "php": "^7.4|^8.0" - }, - "conflict": { - "phpstan/phpstan-shim": "*" - }, - "bin": [ - "phpstan", - "phpstan.phar" - ], - "type": "library", - "autoload": { - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Ondřej Mirtes" - }, - { - "name": "Markus Staab" - }, - { - "name": "Vincent Langlet" - } - ], - "description": "PHPStan - PHP Static Analysis Tool", - "keywords": [ - "dev", - "static analysis" - ], - "support": { - "docs": "https://phpstan.org/user-guide/getting-started", - "forum": "https://github.com/phpstan/phpstan/discussions", - "issues": "https://github.com/phpstan/phpstan/issues", - "security": "https://github.com/phpstan/phpstan/security/policy", - "source": "https://github.com/phpstan/phpstan-src" - }, - "funding": [ - { - "url": "https://github.com/ondrejmirtes", - "type": "github" - }, - { - "url": "https://github.com/phpstan", - "type": "github" - } - ], - "time": "2026-08-22T07:38:16+00:00" - }, { "name": "phpunit/php-code-coverage", "version": "14.2.4", From a5d218fe7b7d8382a26e4267e1e81da5321e068b Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 22:39:48 +0330 Subject: [PATCH 5/8] ci: add GitHub Actions pipeline with Pest Postgres matrix --- .github/workflows/ci.yml | 73 ++++++++++++++++++++++++++++++++++++++++ README.md | 1 + 2 files changed, 74 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..dd7c6ce --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,73 @@ +name: CI + +on: + push: + branches: [main, develop] + pull_request: + branches: [main, develop] + +jobs: + pint: + name: Code Style + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: shivammathur/setup-php@v2 + with: + php-version: "8.3" + extensions: mbstring, xml, ctype, json, bcmath, pdo, pgsql + tools: composer:v2 + coverage: none + - uses: actions/cache@v4 + with: + path: vendor + key: composer-${{ runner.os }}-${{ hashFiles('**/composer.lock') }} + - run: composer install --no-progress --prefer-dist + - run: vendor/bin/pint --test + + test: + name: Tests (${{ matrix.db }}) + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + include: + - db: SQLite + connection: sqlite + - db: PostgreSQL + connection: pgsql + + services: + postgres: + image: postgres:16-alpine + env: + POSTGRES_DB: testing + POSTGRES_USER: root + POSTGRES_PASSWORD: password + ports: + - 5432:5432 + options: >- + --health-cmd pg_isready + --health-interval 10s + --health-timeout 5s + --health-retries 5 + + env: + DB_CONNECTION: ${{ matrix.connection }} + + steps: + - uses: actions/checkout@v4 + - uses: shivammathur/setup-php@v2 + with: + php-version: "8.3" + extensions: mbstring, xml, ctype, json, bcmath, pdo, pgsql, sqlite3 + tools: composer:v2 + coverage: none + - uses: actions/cache@v4 + with: + path: vendor + key: composer-${{ runner.os }}-${{ hashFiles('**/composer.lock') }} + - run: composer install --no-progress --prefer-dist + - run: cp .env.example .env + - run: php artisan key:generate + - run: php artisan test diff --git a/README.md b/README.md index f86b30c..285355e 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,7 @@ Sanctum API v1 MIT + CI

From 37f4f2c329f57e5676f96ae50a9932971a3f3500 Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 22:49:02 +0330 Subject: [PATCH 6/8] ci: run workflows on PHP 8.5 to match locked dependencies --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dd7c6ce..d810ad0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@v2 with: - php-version: "8.3" + php-version: "8.5" extensions: mbstring, xml, ctype, json, bcmath, pdo, pgsql tools: composer:v2 coverage: none @@ -59,7 +59,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@v2 with: - php-version: "8.3" + php-version: "8.5" extensions: mbstring, xml, ctype, json, bcmath, pdo, pgsql, sqlite3 tools: composer:v2 coverage: none From 03e10be5ed2ca49a2dec4508e32f193c52e9f1ca Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 23:10:02 +0330 Subject: [PATCH 7/8] ci: run tests against PostgreSQL via per-matrix PHPUnit config --- .github/workflows/ci.yml | 4 +++- phpunit.pgsql.xml | 40 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 phpunit.pgsql.xml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d810ad0..2a41eba 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,8 +34,10 @@ jobs: include: - db: SQLite connection: sqlite + config: phpunit.xml - db: PostgreSQL connection: pgsql + config: phpunit.pgsql.xml services: postgres: @@ -70,4 +72,4 @@ jobs: - run: composer install --no-progress --prefer-dist - run: cp .env.example .env - run: php artisan key:generate - - run: php artisan test + - run: php artisan test --configuration=${{ matrix.config }} diff --git a/phpunit.pgsql.xml b/phpunit.pgsql.xml new file mode 100644 index 0000000..1257788 --- /dev/null +++ b/phpunit.pgsql.xml @@ -0,0 +1,40 @@ + + + + + tests/Unit + + + tests/Feature + + + + + app + + + + + + + + + + + + + + + + + + + + + + + From 200d3097795b338b0620528fb6d675d37097f410 Mon Sep 17 00:00:00 2001 From: MahdiiMax Date: Fri, 28 Aug 2026 23:17:56 +0330 Subject: [PATCH 8/8] ci: run pest directly to avoid duplicate configuration flag --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2a41eba..93cc554 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -72,4 +72,4 @@ jobs: - run: composer install --no-progress --prefer-dist - run: cp .env.example .env - run: php artisan key:generate - - run: php artisan test --configuration=${{ matrix.config }} + - run: vendor/bin/pest --configuration=${{ matrix.config }}