Commit 410b602c authored by Ghislain Loas's avatar Ghislain Loas
Browse files

Merge branch 'dev#71664_prettyphoto_ko' into 'master'

Dev#71664 prettyphoto ko

See merge request afi/opacce!2507
parents 5f2e1717 2d1ab41d
...@@ -771,13 +771,13 @@ class CmsControllerArticleConcertEditActionTest extends CmsControllerWithPermiss ...@@ -771,13 +771,13 @@ class CmsControllerArticleConcertEditActionTest extends CmsControllerWithPermiss
/** @test */ /** @test */
function previewShouldContainsArticleUrl() { function previewShouldContainsArticleUrl() {
$this->assertXPath('//a[@data-prettyphoto="true"][contains(@href, "/cms/articleview/id/4")]'); $this->assertXPath('//a[contains(@href, "/cms/articleview/id/4")]');
} }
/** @test */ /** @test */
function previewTitleShouldBeVisualisationDeLArticle() { function previewTitleShouldBeVisualisationDeLArticle() {
$this->assertXPath('//a[@data-prettyphoto="true"][contains(@title, "Visualisation de l\'article: Erik Truffaz en concert")]'); $this->assertXPath('//a[contains(@title, "Erik Truffaz en concert")]');
} }
...@@ -811,13 +811,7 @@ class CmsControllerArticleConcertEditRenderPopupActionTest extends CmsController ...@@ -811,13 +811,7 @@ class CmsControllerArticleConcertEditRenderPopupActionTest extends CmsController
/** @test */ /** @test */
public function tagPreviewArticleShouldNotHaveRenderPopupInLink() { public function tagPreviewArticleShouldNotHaveRenderPopupInLink() {
$this->_xpath->assertXPath($this->_json->content, $this->_xpath->assertXPath($this->_json->content,
'//a[contains(@href, "cms/articleview/id/4?iframe=true")]'); '//a[contains(@href, "cms/articleview/id/4")]');
}
/** @test */
public function prettyPhotoShouldBeLoaded() {
$this->_xpath->assertXPath($this->_json->content, '//script[contains(@src, "jquery.prettyPhoto")]');
} }
...@@ -2607,7 +2601,7 @@ class CmsControllerArticleExistingTraductionEditTest extends CmsControllerWithPe ...@@ -2607,7 +2601,7 @@ class CmsControllerArticleExistingTraductionEditTest extends CmsControllerWithPe
/** @test */ /** @test */
function previewShouldContainsArticleUrl() { function previewShouldContainsArticleUrl() {
$this->assertXPath('//a[@data-prettyphoto="true"][contains(@href, "cms/articleview/id/41")]'); $this->assertXPath('//a[contains(@href, "cms/articleview/id/41")]');
} }
} }
......
...@@ -124,13 +124,7 @@ class Admin_ProfilControllerWithAdminPortailIndexTest extends Admin_ProfilContro ...@@ -124,13 +124,7 @@ class Admin_ProfilControllerWithAdminPortailIndexTest extends Admin_ProfilContro
/** @test */ /** @test */
function previewPageAccueilAnchorTitleShouldBeVisualisationDeLaPageAdulte() { function previewPageAccueilAnchorTitleShouldBeVisualisationDeLaPageAdulte() {
$this->assertXPath('//div/ul[1]//li[1]//a[@data-prettyphoto="true"][contains(@title, "Visualisation de la page \'Adulte\'")][@href="/index/index/id_profil/8?iframe=true&width=95%25&height=95%25"]'); $this->assertXPath("//div/ul[1]//li[1]//a[contains(@title, 'Ouvrir la page \"Adulte\"')][@href='/index/index/id_profil/8']");
}
/** @test */
public function prettyPhotoShouldBeLoaded() {
$this->assertXPath('//script[contains(@src, "public/admin/js/prettyphoto/js/jquery.prettyPhoto.js")]');
} }
......
...@@ -167,7 +167,6 @@ class SitothequeControllerSitoEditTest extends SitothequeControllerTestCase { ...@@ -167,7 +167,6 @@ class SitothequeControllerSitoEditTest extends SitothequeControllerTestCase {
/** /**
* @group integration * @group integration
* @disabledtest (anchor with attribute rel = prettyPhoto is not html5 valid)
*/ */
public function pageShouldBeHtml5Valid() { public function pageShouldBeHtml5Valid() {
$this->assertHTML5(); $this->assertHTML5();
......
...@@ -421,12 +421,6 @@ class BibNumeriqueControllerViewAlbumActionPremierVolumeTest extends AbstractBib ...@@ -421,12 +421,6 @@ class BibNumeriqueControllerViewAlbumActionPremierVolumeTest extends AbstractBib
} }
/** @test */
public function viewerScriptShouldBePresent() {
$this->assertXPath('//script[contains(@src, "prettyPhoto.js")]');
}
/** @test */ /** @test */
public function pageBibNumShouldBeHTML5Compliant() { public function pageBibNumShouldBeHTML5Compliant() {
$this->assertHTML5(); $this->assertHTML5();
......
...@@ -358,7 +358,7 @@ class PanierControllerIndexWithPanierIdFifteenTest extends PanierControllerTestC ...@@ -358,7 +358,7 @@ class PanierControllerIndexWithPanierIdFifteenTest extends PanierControllerTestC
/** @test */ /** @test */
public function pageShouldContainsLinkToViewNoticeMontespan() { public function pageShouldContainsLinkToViewNoticeMontespan() {
$this->assertXPath('//a[contains(@href, "/recherche/viewnotice/id/4?iframe=true")]'); $this->assertXPath('//a[contains(@href, "/recherche/viewnotice/id/4")]');
} }
} }
......
...@@ -420,23 +420,13 @@ class BibNumeriqueAlbumTeaserTest extends AbstractBibNumeriqueViewHelperWithAlbu ...@@ -420,23 +420,13 @@ class BibNumeriqueAlbumTeaserTest extends AbstractBibNumeriqueViewHelperWithAlbu
* @depends withoutOrderInPrefShouldRespectInitialOrder * @depends withoutOrderInPrefShouldRespectInitialOrder
* @test * @test
*/ */
public function secondImageShouldLinkToFullImagePrettyPhoto($html) { public function secondImageShouldLinkToFullImage($html) {
$this->assertXPath($html, $this->assertXPath($html,
'//a[contains(@href, "/bib-numerique/get-resource/id/2")][@data-rel="prettyphoto[Harlock]"][@title="Le capitaine en slip"]', '//a[contains(@href, "/bib-numerique/get-resource/id/2")][contains(@title,"Le capitaine en slip")]',
$html); $html);
} }
/** @test */
public function pageShouldContainsCodeToLoadPrettyPhoto() {
$this->_buildHelperLimitedTo(2);
$this->_helper->getBoite();
$this->assertXPath(Class_ScriptLoader::getInstance()->html(),
'//script[contains(@src,"prettyPhoto")]');
}
/** @test */ /** @test */
public function withOrderRespectInPrefShouldRespectInitialOrder() { public function withOrderRespectInPrefShouldRespectInitialOrder() {
$this->_buildHelperLimitedToFourOrderedBy(Class_Systeme_ModulesAccueil_BibliothequeNumerique::ORDER_SELECTION); $this->_buildHelperLimitedToFourOrderedBy(Class_Systeme_ModulesAccueil_BibliothequeNumerique::ORDER_SELECTION);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment