Skip to content

Instantly share code, notes, and snippets.

@ngothoai
Created September 26, 2017 06:53
Show Gist options
  • Save ngothoai/3bbb0e5d25e35fc82858ea84d5df29e6 to your computer and use it in GitHub Desktop.
Save ngothoai/3bbb0e5d25e35fc82858ea84d5df29e6 to your computer and use it in GitHub Desktop.
<?php
/*
|--------------------------------------------------------------------------
| Model Factories
|--------------------------------------------------------------------------
|
| Here you may define all of your model factories. Model factories give
| you a convenient way to create models for testing and seeding your
| database. Just tell the factory how a default model should look.
|
*/
/** @var \Illuminate\Database\Eloquent\Factory $factory */
$factory->define(App\User::class, function (Faker\Generator $faker) {
return [
'name' => $faker->name,
'age' => $faker->age,
'address' => $faker->address,
'photo' => $faker->photo,
];
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment