diff --git a/application/modules/telephone/views/scripts/recherche/simple.phtml b/application/modules/telephone/views/scripts/recherche/simple.phtml index 770cf4eea74530a0aba1964ddc4cfdc2990afb83..3a82ab810889bed5222c33cdb02424faf17d30f2 100644 --- a/application/modules/telephone/views/scripts/recherche/simple.phtml +++ b/application/modules/telephone/views/scripts/recherche/simple.phtml @@ -1,8 +1,7 @@ <ul data-role="listview"> <?php echo $this->toolbar("Recherche", $this->url(array(), null, true)); -echo $this->tagTitreEtNombreDeResultats($this->search_result->getRecordsCount(), - $this->criteres_recherche); +echo $this->tagTitreEtNombreDeResultats($this->search_result, $this->search_duration); echo $this->listeNotices($this->search_result->fetchRecords(), diff --git a/tests/application/modules/opac/controllers/RechercheControllerTest.php b/tests/application/modules/opac/controllers/RechercheControllerTest.php index 4f400ae547a77d7e2d66917b88ef54fc5217208b..ccddbd6831f3e4014a5d95a5e2fc1d3f1ad5d31a 100644 --- a/tests/application/modules/opac/controllers/RechercheControllerTest.php +++ b/tests/application/modules/opac/controllers/RechercheControllerTest.php @@ -1107,10 +1107,14 @@ class RechercheControllerSimpleActionWithDefaultConfigTest extends RechercheCont Class_Profil::getCurrentProfil()->setCfgModules([]); $this->dispatch('/recherche/simple/expressionRecherche/pomme/tri/alpha_auteur',true); - } + /** @test */ + public function pageShouldContainsSearchDurationInSecondes() { + $this->assertXPathContentContains('//div', 'secondes)'); + } + /** @test */ public function pageShouldContainsLinkToAtomFormat() { diff --git a/tests/application/modules/telephone/controllers/RechercheControllerTest.php b/tests/application/modules/telephone/controllers/RechercheControllerTest.php index 2eec4626e4921b6d71c8f672a8c5159ba2f7ea03..dc0e00c1b5909637ac094568a51c20811ab30702 100644 --- a/tests/application/modules/telephone/controllers/RechercheControllerTest.php +++ b/tests/application/modules/telephone/controllers/RechercheControllerTest.php @@ -25,7 +25,7 @@ require_once 'TelephoneAbstractControllerTestCase.php'; class Telephone_RechercheControllerSimpleSeveralInexistingWordsActionTest extends TelephoneAbstractControllerTestCase { public function setUp() { parent::setUp(); - $this->dispatch('/telephone/recherche/simple/expressionRecherche/zzriuezz+greuieub+brfauiok'); + $this->dispatch('/telephone/recherche/simple/expressionRecherche/zzriuezz+greuieub+brfauiok', true); } @@ -99,6 +99,12 @@ class Telephone_RechercheControllerSimpleByPertinenceActionTest extends Telephon public function pageShouldNotDisplayAucunResultat() { $this->assertNotXPathContentContains('//span', 'Aucun résultat trouvé'); } + + + /** @test */ + public function pageShouldContainsSearchDurationInSecondes() { + $this->assertXPathContentContains('//div', 'secondes)'); + } }