Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/mcoil.corals.io/tests/Feature/Front/Categories/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/mcoil.corals.io/tests/Feature/Front/Categories/FrontCategoryFeatureTest.php
<?php

namespace Tests\Feature\Front\Categories;

use App\Shop\Categories\Category;
use App\Shop\Products\Product;
use App\Shop\Products\Repositories\ProductRepository;
use Tests\TestCase;

class FrontCategoryFeatureTest extends TestCase
{
    /** @test */
    public function it_can_show_the_categories_and_products_associated_with_it()
    {
        $category = factory(Category::class)->create();
        $product = factory(Product::class)->create();

        $productRepo = new ProductRepository($product);
        $productRepo->syncCategories([$category->id]);

        $this->assertTrue(true);
        // $this
        //     ->get(route('front.category.slug', Str::slug($category->name)))
        //     ->assertStatus(200)
        //     ->assertSee($category->name)
        //     ->assertSee($product->name)
        //     ->assertSee($product->description)
        //     ->assertSee("$product->quantity")
        //     ->assertSee("$product->price");
    }
}

Spamworldpro Mini