From 65ad212d4cf42e555422ec2f9bbcde922b9bf068 Mon Sep 17 00:00:00 2001
From: pbarroca <pbarroca@afi-sa.fr>
Date: Tue, 17 Jan 2017 15:12:38 +0100
Subject: [PATCH] dev #53508 fix assertion

---
 .../controllers/IntegrationControllerTest.php | 19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)

diff --git a/cosmogramme/cosmozend/tests/application/modules/cosmo/controllers/IntegrationControllerTest.php b/cosmogramme/cosmozend/tests/application/modules/cosmo/controllers/IntegrationControllerTest.php
index 0945b7acbfa..c314429cf47 100644
--- a/cosmogramme/cosmozend/tests/application/modules/cosmo/controllers/IntegrationControllerTest.php
+++ b/cosmogramme/cosmozend/tests/application/modules/cosmo/controllers/IntegrationControllerTest.php
@@ -21,11 +21,26 @@
 
 
 class Cosmo_IntegrationControllerTestActionTest extends CosmoControllerTestCase {
+  protected $_service;
+
+  public function setUp() {
+    parent::setUp();
+    $this->_service = $this->mock()->whenCalled('test')->answers('');
+    Class_WebService_SIGB_Nanook::setService($this->_service);
+  }
+
+
+  public function tearDown() {
+    Class_WebService_SIGB_Nanook::reset();
+    parent::tearDown();
+  }
+
+
 	/** @test */
-	public function responseShouldContainGetHeader() {
+	public function shouldHaveCalledServiceTestMethod() {
 		$this->dispatch('/cosmo/integration/test?type=7&options[url_serveur]=' . urlencode('http://localhost/ilsdi'), true);
 
-		$this->assertXPathContentContains('//*', 'GET /ilsdi/service/GetRecords/id/1 HTTP/1.1', $this->_response->getBody());
+		$this->assertTrue($this->_service->methodHasBeenCalled('test'));
 	}
 }
 
-- 
GitLab