We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 34e1453 commit 01edf81Copy full SHA for 01edf81
tests/Feature/RoutesTest.php
@@ -13,9 +13,20 @@ public function testRoute()
13
'HTTP_HOST' => 'example.com',
14
'REQUEST_METHOD' => 'GET',
15
'REQUEST_URI' => '/',
16
- ], [], [], [], []));
+ ]));
17
18
$this->assertResponseOk();
19
- $this->assertEquals('<h1>Hello World!</h1>', $response);
+ $this->assertEquals('<h1>Hello world!</h1>', $response);
20
+ }
21
+
22
+ public function testNotFoundRoute()
23
+ {
24
+ $response = $this->runRequest(ServerRequestFactory::fromGlobals([
25
+ 'HTTP_HOST' => 'example.com',
26
+ 'REQUEST_METHOD' => 'GET',
27
+ 'REQUEST_URI' => '/test',
28
29
+ $this->assertResponseCodeEquals(404);
30
+ $this->assertEquals('File not found.', $response);
31
}
32
0 commit comments