thtg88 / laravel-base-classes
A set of useful Laravel classes to be used during everyday development.
Requires
- php: ^8.0
- laravel/framework: ^8.22
- ramsey/uuid: ^4.1
- thtg88/journalism: ^0.1.3
- vinkla/shield: ^7.1
Requires (Dev)
- ext-xdebug: *
- brainmaestro/composer-git-hooks: ^2.8
- friendsofphp/php-cs-fixer: ^2.17
- infection/infection: ^0.21.0
- orchestra/testbench: ^6.7
- phpunit/phpunit: ^9.5
- psalm/plugin-laravel: ^1.4
- vimeo/psalm: ^4.6
This package is auto-updated.
Last update: 2022-05-10 22:06:10 UTC
README
A set of useful Laravel classes to be used across every day development.
Table of Contents
Installation
composer require thtg88/laravel-base-classes
You can publish the configuration file and views by running:
php artisan vendor:publish --provider="Thtg88\LaravelBaseClasses\LaravelBaseClassesServiceProvider"
Usage
Coming soon!
Development
Clone the repo:
git clone git@github.com:thtg88/laravel-base-classes.git
Requirements
The Xdebug PHP extension is required, you can install it via:
pecl install xdebug
Lint
Linting is performed using PHP CS Fixer, you can run that with:
composer run-script check-style
Static Analysis
Static Analysis is run using Psalm, you can run that with:
composer run-script stan
Tests
Tests are run using PHPUnit, you can run them using:
composer run-script test
Mutation Tests
Mutation tests are run using PHPUnit to generate coverage first, and later with Infection.
In order to run mustation tests, first run the following in order to generate the coverage in XML format in the build
directory:
XDEBUG_MODE=coverage ./vendor/bin/phpunit \ --coverage-xml=build/coverage-xml \ --log-junit=build/coverage-xml/phpunit.junit.xml
Then you can run mutation tests with:
./vendor/bin/infection --coverage=build/coverage-xml
License
Laravel Base Classes is open-sourced software licensed under the MIT license.
Security Vulnerabilities
If you discover a security vulnerability within Laravel Base Classes, please send an e-mail to Marco Marassi at security@marco-marassi.com. All security vulnerabilities will be promptly addressed.