Tests for the course pages

Daniel Tanaka 1 year ago
parent 4ae64f6267 commit ac2f1562872c661a39273cd25a123a818b4a01f9
1 changed files with 18 additions and 0 deletions
+18-0tests/Feature/CoursePagesTest.php ADDED
@@ -0,0 +1,18 @@
1+<?php
2+
3+namespace Tests\Feature;
4+
5+use Tests\TestCase;
6+
7+class CoursePagesTest extends TestCase
8+{
9+ public function test_course_list_loads()
10+ {
11+ $this->get('/courses')->assertOk()->assertSee('Python');
12+ }
13+
14+ public function test_unknown_course_is_404()
15+ {
16+ $this->get('/courses/nope')->assertNotFound();
17+ }
18+}