Beispiel #1
0
 public function testHasParam()
 {
     $_REQUEST = ['foo' => 'Foo', 'bar' => 'Bar'];
     $request = new Request(new Session(), new Cookie());
     $this->assertTrue($request->hasParam('foo'));
     $this->assertTrue($request->hasParam('bar'));
     $this->assertFalse($request->hasParam('baz'));
 }
Beispiel #2
0
 /**
  * @return bool
  */
 public function isSent()
 {
     if (!$this->request) {
         return false;
     }
     return $this->request->hasParam($this->name) || $this->request->hasFiles($this->name);
 }