示例#1
0
 public function testRouteRegister()
 {
     // This will pass
     $this->assertTrue(Route::get('/foo/bar', __DIR__ . '/foo/bar.php'));
     // This will fail because same route cannot be registered again
     $this->assertFalse(Route::get('/foo/bar', __DIR__ . '/foo/bar.php'));
     // This can be registerd because it is a different method
     $this->assertTrue(Route::post('/foo/bar', __DIR__ . '/foo/bar.php'));
 }