Exemplo n.º 1
0
 public function testInPageRdf()
 {
     $this->agent->RegisterModelMaker('MwRdf_InPage_Modeler');
     $model = $this->agent->buildModel('inpage');
     $expected_model = MwRdfTest::createExpectedInPageModel();
     $this->assertModelEqualsModel($expected_model, $model);
 }
Exemplo n.º 2
0
 public function testSpecialPageProducesCorrectInPageModel()
 {
     $this->format = 'turtle';
     $parser = MwRdf::Parser('turtle');
     $this->prepareRequest(null, array('inpage'));
     $text = wfRdfSpecialPage(null);
     $model = MwRdf::Model();
     $model->loadStatementsFromString($parser, $text);
     $expect = MwRdfTest::createExpectedInPageModel();
     $this->assertModelEqualsModel($expect, $model);
 }
Exemplo n.º 3
0
 public function testQueryProducesExpectedModel()
 {
     $this->agent->storeModel('inpage');
     $model = $this->agent->retrieveModel('inpage');
     $expect = MwRdfTest::createExpectedInPageModel();
     $this->assertModelEqualsModel($expect, $model);
 }