<?php

namespace Database\Seeders;

use App\Models\Article;
use App\Models\Category;
use App\Models\Contact;
use App\Models\Referral;
use App\Models\Tag;
use App\Models\Testimonial;
use App\Models\User;
use Illuminate\Database\Seeder;

class DatabaseSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        User::factory([
            'name' => 'Sanish Gurung',
            'email' => 'sanish@gmail.com',
        ])->create();

        Article::factory()
            ->count(10)
            ->has(Category::factory()->count(2))
            ->has(Tag::factory()->count(2))
            ->create();

        Contact::factory()
            ->count(10)
            ->create();

        Referral::factory()
            ->count(10)
            ->create();

        Testimonial::factory()
            ->count(10)
            ->create();
    }
}
