Esempio n. 1
0
 private function M()
 {
     $cls = 'FruitTest\\RouteKit\\Handler';
     $mux = new Mux();
     $mux->get('/', array($cls, 'inj'));
     return $mux;
 }
Esempio n. 2
0
 private function M($i, $o)
 {
     $cls = 'FruitTest\\RouteKit\\Handler';
     $mux = new Mux();
     $mux->setFilters($i, $o);
     $mux->get('/', array($cls, 'filter'));
     return $mux;
 }
Esempio n. 3
0
 /**
  * @requires PHP 7
  * @expectedException Exception
  */
 public function testUnsupportedType()
 {
     $cls = 'FruitTest\\RouteKit\\Handler7';
     $mux = new Mux();
     $mux->get('/p/:', array($cls, 'params2'));
     $actual = $mux->dispatch('GET', '/p/a');
 }
Esempio n. 4
0
 /**
  * @requires PHP 7
  * @expectedException Exception
  */
 public function testUnsopportedType()
 {
     $cls = 'FruitTest\\RouteKit\\Handler7';
     $mux = new Mux();
     $mux->get('/p/:', array($cls, 'params2'));
     $mux->compile();
 }
Esempio n. 5
0
 public function setup(\Fruit\RouteKit\Mux $mux)
 {
     $mux->setInterceptor($this);
 }