1.7 - Testing Query Scopes

This commit is contained in:
Adam Wathan
2016-11-03 15:05:59 -04:00
parent 1a5f7c7e89
commit 12e18f3728
4 changed files with 24 additions and 2 deletions

View File

@@ -11,7 +11,7 @@ class ViewConcertListingTest extends TestCase
use DatabaseMigrations;
/** @test */
function user_can_view_a_concert_listing()
function user_can_view_a_published_concert_listing()
{
$concert = Concert::create([
'title' => 'The Red Chord',
@@ -24,6 +24,7 @@ class ViewConcertListingTest extends TestCase
'state' => 'ON',
'zip' => '17916',
'additional_information' => 'For tickets, call (555) 555-5555.',
'published_at' => Carbon::parse('-1 week'),
]);
$this->visit('/concerts/'.$concert->id);