createXMLDataSet(dirname(__FILE__).'/fixtures/sessions_empty.xml'); } public function setUp() { $this->session_factory = new phpbb_session_testable_factory; $this->db = $this->new_dbal(); } function test_extract_current_page() { $expected_fields = array( 'page_name' => "index.php", 'script_path' => "/phpBB/" ); $output = phpbb_session_testable_facade::extract_current_page( $this->db, $this->session_factory, /* Root Path */ "./", /* PHP Self */ "/phpBB/index.php", /* Query String*/ "", /* Request URI */ "/phpBB/" ); foreach($expected_fields as $field => $expected_value) { $this->assertSame($expected_value, $output[$field]); } } }