request = new Request(new App()); $_POST = []; $_GET = []; } //-------------------------------------------------------------------- public function testFetchGlobalsSingleValue() { $_POST['foo'] = 'bar'; $_GET['bar'] = 'baz'; $this->assertEquals('bar', $this->request->fetchGlobal('post', 'foo')); $this->assertEquals('baz', $this->request->fetchGlobal('get', 'bar')); } public function testFetchGlobalsReturnsNullWhenNotFound() { $this->assertNull($this->request->fetchGlobal('post', 'foo')); } public function testFetchGlobalsFiltersValues() { $this->request->setGlobal('post', [ 'foo' => 'bar