rename ModelFactory to UserFactory to encourage separate files

This commit is contained in:
Taylor Otwell 2017-04-11 10:41:19 -05:00
parent 8abc4d05c5
commit 67a8a11570
1 changed files with 7 additions and 4 deletions

View File

@ -1,18 +1,21 @@
<?php <?php
use App\User;
use Faker\Generator as Faker;
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| Model Factories | Model Factories
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------
| |
| Here you may define all of your model factories. Model factories give | This directory should contain each of the model factory definitions for
| you a convenient way to create models for testing and seeding your | your application. Factories provide a convenient way to generate new
| database. Just tell the factory how a default model should look. | model instances for testing / seeding your application's database.
| |
*/ */
/** @var \Illuminate\Database\Eloquent\Factory $factory */ /** @var \Illuminate\Database\Eloquent\Factory $factory */
$factory->define(App\User::class, function (Faker\Generator $faker) { $factory->define(User::class, function (Faker $faker) {
static $password; static $password;
return [ return [