Skip to content
Snippets Groups Projects
Commit 13bd7fea authored by Ghislain Loas's avatar Ghislain Loas
Browse files

dev #75659 add test button in catalog edit form

parent 1da64928
Branches
Tags
3 merge requests!2676Master,!2671dev #75659 add test button in catalog edit form,!2668dev #75659 add test button in catalog edit form
Pipeline #4243 passed with stage
in 36 minutes and 51 seconds
- ticket #75659 : Administration : ajout du bouton tester dans le formulaire de modification d'un domaine.
\ No newline at end of file
<?php echo $this->renderForm($this->form); ?>
<?php
if(!$this->catalogue->isNew())
echo $this->tag('div',
$this->tagAnchor($this->url(['action' => 'tester',
'id_catalogue' => $this->catalogue->getId()]),
Class_Admin_Skin::current()
->renderActionIconOn('test',
$this,
['alt' => $this->_('Tester'),
'title' => $this->_('Tester le catalogue "%s"',
$this->catalogue->getLibelle())]),
['data-popup' => true]),
['class' => 'header_actions']);
echo $this->renderForm($this->form);
......@@ -270,7 +270,7 @@ class CatalogueControllerWithAdminBibAndRightTotalAccessTest extends AdminCatalo
/** @test */
public function editCatalogueShouldShowValiderButton() {
$this->dispatch('/admin/catalogue/edit/id_catalogue/300');
$this->dispatch('/admin/catalogue/edit/id_catalogue/300', true);
$this->assertXPathContentContains('//button', 'Valider');
}
......@@ -785,6 +785,12 @@ class CatalogueControllerEditCatalogueTest extends AdminCatalogueControllerTestC
public function shouldNotContainsAnnexeNoveltyThesaurus() {
$this->assertNotXPath('//input[@name="NANA"]');
}
/** @test */
public function shouldContainsPopupLinkToTestAction() {
$this->assertXPath('//a[contains(@href, "/tester/id_catalogue/6")][@data-popup]');
}
}
......@@ -1737,4 +1743,4 @@ class Admin_CatalogueControllerActionDomainesTestCase extends AbstractController
$this->dispatch('/admin/catalogue/domaines', true);
$this->assertNotRedirect();
}
}
}
\ No newline at end of file
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