Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
19 lines (16 sloc) 365 Bytes
<?php
use Illuminate\Database\Seeder;
class ArticleSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
factory(App\Article::class, 25)->create()->each(function ($article) {
factory(App\Comment::class, 5)->create(['article_id' => $article->id]);
});
}
}