From 1589d8e3498d8110fa09802de6a8d0fad2297698 Mon Sep 17 00:00:00 2001
From: llaffont <llaffont@git-test.afi-sa.fr>
Date: Thu, 28 Nov 2013 11:13:42 +0000
Subject: [PATCH] Correction option kiosque "afficher les notices avec
 vignettes uniquement" + tests

---
 .../modules/admin/views/scripts/accueil/kiosque.phtml  | 10 ++++++++++
 .../admin/controllers/AccueilControllerTest.php        |  7 +++++++
 2 files changed, 17 insertions(+)

diff --git a/application/modules/admin/views/scripts/accueil/kiosque.phtml b/application/modules/admin/views/scripts/accueil/kiosque.phtml
index ca78aa9cab8..c8eeb7b20b4 100644
--- a/application/modules/admin/views/scripts/accueil/kiosque.phtml
+++ b/application/modules/admin/views/scripts/accueil/kiosque.phtml
@@ -69,6 +69,16 @@
 						</span>
 					</td>
     		</tr>
+
+				<tr>
+    			<td class="droite">Vignettes&nbsp;</td>
+    			<td class="gauche"><?php echo $this->formSelect("only_img",
+																													$this->preferences["only_img"],
+																													"",
+																													["0" => "Afficher le titre dans une image",
+																													 "1" => "Afficher les notices avec vignettes uniquement"]) ?></td>
+				</tr> 
+
   		</table>
 			</fieldset>
 			<br />
diff --git a/tests/application/modules/admin/controllers/AccueilControllerTest.php b/tests/application/modules/admin/controllers/AccueilControllerTest.php
index 1ac36a3b032..f965a603a53 100644
--- a/tests/application/modules/admin/controllers/AccueilControllerTest.php
+++ b/tests/application/modules/admin/controllers/AccueilControllerTest.php
@@ -636,6 +636,13 @@ class AccueilControllerConfigBoiteKiosqueProfilLognesAsAdminPortailTest extends
 	public function selectStyleListeShouldContainsOptGroupObjetsHTMLChrono() {
 		$this->assertXPathContentContains('//select[@name="style_liste"]//option[@value="chrono"]', 'Frise');
 	}
+
+
+	/** @test */
+	public function selectOnlyImgShouldBeOnAfficheNoticesAvecVignettes() {
+		$this->assertXPathContentContains('//select[@name="only_img"]/option[@value="1"][@selected="selected"]',
+																			'Afficher les notices avec vignettes uniquement');
+	}
 }
 
 
-- 
GitLab