About this package
This package contains artisan make:crud
commands to create a simple CRUD feature with test classes on our Laravel 5.5 (and later) application. This package is fairly simple, to boost test-driven development method on our laravel application.
With this package installed on local environment, we can use (e.g.) php artisan make:crud Vehicle
command to generate some files :
App\Models\Vehicle.php
eloquent modelxxx_create_vehicles_table.php
migration fileVehicleController.php
index.blade.php
andforms.blade.php
view file inresources/views/vehicles
directoryresources/lang/vehicle.php
lang fileVehicleFactory.php
model factory fileVehiclePolicy.php
model policy file inapp/Policies
directoryManageVehiclesTest.php
feature test class intests/Feature
directoryVehicleTest.php
unit test class intests/Unit/Models
directoryVehiclePolicyTest.php
unit test class intests/Unit/Policies
directory
It will update some file :
- Update
routes/web.php
to addvehicles
resource route - Update
app/providers/AuthServiceProvider.php
to add Vehicle model Policy class in$policies
property
It will also create this file if it not exists :
resources/lang/app.php
lang file if it not existstests/BrowserKitTest.php
base Feature TestCase class if it not exists
Main purpose
The main purpose of this package is for faster Test-driven Development, it generates model CRUD scaffolds complete with Testing Classes which will use Laravel Browserkit Testing package and PHPUnit.