rymanalu / factory-generator

Laravel 5 Model Factory Generator
MIT License
17 stars 4 forks source link

Lumen Class path.database does not exist #2

Open j3rrey opened 5 years ago

j3rrey commented 5 years ago

Trying to run this in Lumen gives me on php artisan make app....

Class path.database does not exist

j3rrey commented 5 years ago

fixed with: $this->app->instance('path.database', app()->basePath() . DIRECTORY_SEPARATOR . 'config'); Provided you have a database.php in your config folder.

Altho there is an issue, Factories are being created in the model Namespace And it seems this generator is not smart enough to detect the different types... :(

e.g. 'created_at' => $faker->word, 'updated_at' => $faker->word,