Thank you for considering contributing to the JOOservices Client!
We adhere to strict coding standards to ensure high quality and maintainability.
- PSR-12: Code style is enforced via Laravel Pint.
- Static Analysis: We use PHPStan at the highest level.
- Testing: All features must be covered by tests using PHPUnit (PHPUnit 12).
-
Fork the repository.
-
Clone your fork locally.
-
Install Dependencies:
composer install -
Create a Branch:
git checkout -b feature/my-new-feature -
Develop your changes.
-
Run Quality Checks: Ensure everything passes before pushing.
composer lint:fix composer lint:all composer testUse
composer test:coveragewhen you need the enforced 98% coverage gate. -
Commit: Use Conventional Commit messages such as
feat(http): Add retry header propagation. -
Push and Create Pull Request.
composer installauto-installs CaptainHook hooks.- Pre-commit runs PHP linting,
gitleaks protect --staged,composer lint:pint,composer lint:phpcs, andcomposer lint:phpstan. - Pre-push runs
composer testand an unpushed-commits gitleaks scan whengitleaksis available locally.
We use a "Real Component" testing strategy:
- Feature Tests (
tests/Feature/): Verify real side effects (file I/O) and integrations usingGuzzle\MockHandlerfor the network layer only. - Benchmarks (
tests/Benchmark/): Ensure no performance regression.
Run tests:
composer test
composer test:coverageIf you discover a security vulnerability, please report it privately instead of using the issue tracker.