public function testHelpers() { $this->assertEquals(url(), \PHPPE\Http::url(), "url wrapper"); $this->assertEquals("a", basename(url("a")), "url app"); $this->assertEquals("a", basename(dirname(url("a", "b"))), "url action #1"); $this->assertEquals("b", basename(url("a", "b")), "url action #2"); $_SESSION['pe_r'] = ""; \PHPPE\Http::_r(); $this->assertNotEmpty($_SESSION['pe_r'], "redirect save"); @\PHPPE\Http::mime("text/plain", true); @\PHPPE\Http::mime("text/plain", false); }
function url($m = null, $p = null) { return \PHPPE\Http::url($m, $p); }