Skip to content

Commit

Permalink
Fixed up another test
Browse files Browse the repository at this point in the history
  • Loading branch information
lordtatty committed Aug 6, 2015
1 parent 382eb99 commit f26ebb5
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions test/unit/mongo/MongoSearchProviderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -453,17 +453,16 @@ public function testSearchSingleIndex()

public function testSearchMultipleIndices()
{
$results = $this->searchProvider->search("bibo:Book", "i_search_resource", array("search_terms","other_terms"), array("result","rdftype"), 4, 0);
$results = $this->searchProvider->search("bibo:Book", "i_search_resource", array("search_terms","other_terms"), array("result","rdftype"), 3, 0);
$this->assertEquals(13, $results['head']['count']);
$this->assertEquals(4, $results['head']['limit']);
$this->assertEquals(4, count($results['results']));
$this->assertEquals(3, $results['head']['limit']);
$this->assertEquals(3, count($results['results']));
$this->assertEquals(0, $results['head']['offset']);
$this->assertEquals("bibo:Book",$results['head']["query"]);
$this->assertEquals(array("bibo:book"), $results['head']["query_terms_used"]);
$this->assertArrayHasKey("duration", $results['head']);

$expectedResults = array(
array("result"=>array("title"=>"Droit du contentieux administratif" , "link"=>"http://talisaspire.com/resources/doc13" , "author"=>"René Chapus"), "rdftype"=>"bibo:Book"),
array("result"=>array("title"=>"Physics for Engineers and Scientists" , "link"=>"http://talisaspire.com/resources/doc1" , "author"=>"Sayid Jarrah"), "rdftype"=>"bibo:Book"),
array("result"=>array("title"=>"Astrophysics for Beginners" , "link"=>"http://talisaspire.com/resources/doc2" , "author"=>"Sayid Jarrah"), "rdftype"=>"bibo:Book"),
array("result"=>array("title"=>"Fundementals of Heat and Mass Transfers" , "link"=>"http://talisaspire.com/resources/doc3" , "author"=>"Sayid Jarrah"), "rdftype"=>"bibo:Book")
Expand Down

0 comments on commit f26ebb5

Please sign in to comment.