ClearBowl/api/tests/Feature/ProductsTest.php

20 lines
406 B
PHP
Raw Normal View History

2020-01-19 20:21:41 +01:00
<?php
namespace Tests\Feature;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Tests\TestCase;
class ProductsTest extends TestCase
{
use RefreshDatabase;
public function testGetProducts()
{
$response = $this->get('http://localhost:8000/api/product');
$response->assertStatus(200);
$response->assertJsonStructure(['success', 'data' => ['products']]);
}
}