Commit 240315c6 authored by Ylan Fleurant's avatar Ylan Fleurant

compat php 7.3

parent 04de5b11
Pipeline #7615 failed with stage
......@@ -27,7 +27,7 @@ class AssimilConfigTest extends ModelTestCase {
$_config;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->_config = Assimil_Config::getInstance();
}
......@@ -60,7 +60,7 @@ class AssimilNotActivatedAdminTest extends Admin_AbstractControllerTestCase {
$_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::resetAllVars();
$this->dispatch('/admin/index/adminvar', true);
......@@ -89,7 +89,7 @@ abstract class AssimilActivatedTestCase extends Admin_AbstractControllerTestCase
$_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_DigitalResource::resetInstance();
Class_AdminVar::set('Assimil_Assimil', '1');
......@@ -102,7 +102,7 @@ abstract class AssimilActivatedTestCase extends Admin_AbstractControllerTestCase
class AssimilActivatedAdminTest extends AssimilActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$bib = $this->fixture('Class_Bib',
['id' => 2,
......@@ -226,7 +226,7 @@ class AssimilActivatedAdminTest extends AssimilActivatedTestCase {
class AssimilOpacIndexControllerWithMenuTest extends AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Assimil_Assimil', 1);
$cfg_menus = ['H' => ['libelle' => 'Menu horizontal',
......@@ -272,7 +272,7 @@ abstract class AssimilServiceTestCase extends ModelTestCase {
$_e_course;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Assimil_Assimil', 1);
......@@ -398,7 +398,7 @@ class AssimilServiceHarvestTest extends AssimilServiceTestCase {
class AssimilServiceSecondHarvestTest extends AssimilServiceTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$catalogue_xml = file_get_contents(__DIR__ . '/catalogue_XML_Assimil_V2_second.xml');
......@@ -453,7 +453,7 @@ abstract class AssimilAjaxRecordTestCase extends AbstractControllerTestCase {
$_record;
public function setUp() {
public function setUp() : void {
parent::setUp();
$ressource = $this->fixture('Class_AlbumRessource',
......@@ -481,7 +481,7 @@ class AssimilAjaxRecordWithNoLoggedUserDispatchTest extends AssimilAjaxRecordTes
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->clearIdentity();
......@@ -500,7 +500,7 @@ class AssimilAjaxRecordWithNoLoggedUserDispatchTest extends AssimilAjaxRecordTes
class AssimilAjaxRecordWithLoggedUserDispatchTest extends AssimilAjaxRecordTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->logUser($this->fixture('Class_Users',
......@@ -523,7 +523,7 @@ class AssimilAjaxRecordWithLoggedUserDispatchTest extends AssimilAjaxRecordTestC
class AssimilModuleIndexControllerTest extends AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->fixture('Class_AdminVar',
......@@ -607,7 +607,7 @@ class AssimilBibnumControllerIndexTest extends Admin_AbstractControllerTestCase
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->dispatch('/admin/bibnum', true);
}
......@@ -628,7 +628,7 @@ abstract class AssimilModulesControllerAssimilTestCase extends AbstractControlle
$_group;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::init();
Class_AdminVar::set('Assimil_Assimil', 1);
......@@ -641,7 +641,7 @@ abstract class AssimilModulesControllerAssimilTestCase extends AbstractControlle
class AssimilModulesControllerAssimilNoAccessRightTest extends AssimilModulesControllerAssimilTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->logUser($this->fixture('Class_Users',
['id' => 1,
......@@ -661,7 +661,7 @@ class AssimilModulesControllerAssimilNoAccessRightTest extends AssimilModulesCon
abstract class AssimilModulesControllerAssimilLoggedUserTestCase extends AssimilModulesControllerAssimilTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->logUser($this->fixture('Class_Users',
['id' => 1,
......@@ -707,7 +707,7 @@ class AssimilModulesControllerAssimilLoggedTest extends AssimilModulesController
class AssimilModulesControllerAssimilLoggedWithAlbumTest extends AssimilModulesControllerAssimilLoggedUserTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->fixture('Class_Album',
......@@ -730,7 +730,7 @@ class AssimilModulesControllerAssimilLoggedWithAlbumTest extends AssimilModulesC
class AssimilRechercheControllerWithFacetTest extends AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->mock_sql = $this->mock()
......@@ -754,7 +754,7 @@ class AssimilRechercheControllerWithFacetTest extends AbstractControllerTestCase
class AssimilMigrationToV2Tests extends AssimilActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Assimil_SSO_URL', 'https://assimil.old.com');
......
......@@ -120,7 +120,7 @@ class ModulesControllerBibliondemandSsoTest extends AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->fixture('Class_AdminVar',
......@@ -184,7 +184,7 @@ class BibliondemandLibDocTypesTests extends ModelTestCase {
$_file_content = '';
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->fixture('Class_IntProfilDonnees',
......@@ -273,7 +273,7 @@ class BibliondemandMissingDocTypesTests extends Admin_AbstractControllerTestCase
protected $_storm_default_to_volatile = true;
public function tearDown() {
public function tearDown() : void {
Bibliondemand_Lib_DocTypesFinder::reset();
parent::tearDown();
}
......@@ -317,7 +317,7 @@ class BibliondemandIndexThesauriBatchTests extends ModelTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
Bibliondemand_Lib_IndexThesauri::setTimeSource((new TimeSourceForTest('2018-10-22 10:00:00')));
......@@ -337,7 +337,7 @@ class BibliondemandIndexThesauriBatchTests extends ModelTestCase {
}
public function tearDown() {
public function tearDown() : void {
Bibliondemand_Lib_DocTypesFinder::reset();
Bibliondemand_Lib_IndexThesauri::reset();
parent::tearDown();
......@@ -462,7 +462,7 @@ class BibliondemandSsoByProviderTests extends Admin_AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->fixture('Class_AdminVar',
......
......@@ -25,7 +25,7 @@ class CapturatorModulesControllerTest extends AbstractControllerTestCase {
$_storm_default_to_volatile = true,
$_user;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Capturator_SSO_URL',
'https://sillabi.com/fr/connector/chambe');
......
......@@ -27,7 +27,7 @@ abstract class CvsActivatedTestCase extends AbstractControllerTestCase {
$_user;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Cvs_BMKEY', '22222');
......@@ -75,7 +75,7 @@ abstract class CvsActivatedTestCase extends AbstractControllerTestCase {
}
public function tearDown() {
public function tearDown() : void {
Class_WebService_Abstract::setHttpClient(null);
parent::tearDown();
}
......@@ -86,7 +86,7 @@ abstract class CvsActivatedTestCase extends AbstractControllerTestCase {
abstract class CvsActivatedAdminLoggedTestCase extends CvsActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$admin = $this->fixture('Class_Users',
['id' => 78,
......@@ -103,7 +103,7 @@ abstract class CvsActivatedAdminLoggedTestCase extends CvsActivatedTestCase {
class CvsDashboardTest extends CvsActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->dispatch('/Cvs_Plugin/index', true);
}
......@@ -144,7 +144,7 @@ class CvsModuleMenuTest extends CvsActivatedTestCase {
class CvsSsoTest extends CvsActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->logUser($this->_user);
}
......@@ -172,7 +172,7 @@ class CvsSsoTest extends CvsActivatedTestCase {
abstract class CvsActivatedBorrowerLoggedTestCase extends CvsActivatedTestCase {
public function setup() {
public function setUp() : void {
parent::setup();
Class_AdminVar::newInstanceWithId('Cvs_LOGINTEST',
......@@ -189,7 +189,7 @@ abstract class CvsActivatedBorrowerLoggedTestCase extends CvsActivatedTestCase {
class CvsSearchFromGooglebotTest extends CvsActivatedBorrowerLoggedTestCase {
protected $_backup_useragent;
public function setUp() {
public function setUp() : void {
parent::setUp();
$_SERVER['HTTP_USER_AGENT'] = 'Googlebot/2.1';
......@@ -197,7 +197,7 @@ class CvsSearchFromGooglebotTest extends CvsActivatedBorrowerLoggedTestCase {
}
public function tearDown() {
public function tearDown() : void {
unset($_SERVER['HTTP_USER_AGENT']);
parent::tearDown();
}
......@@ -213,7 +213,7 @@ class CvsSearchFromGooglebotTest extends CvsActivatedBorrowerLoggedTestCase {
class CvsSearchWithResultsTest extends CvsActivatedBorrowerLoggedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$web_client = $this->mock()
......@@ -249,7 +249,7 @@ class CvsSearchWithResultsTest extends CvsActivatedBorrowerLoggedTestCase {
class CvsNoticeAjaxControllerCvsSearchWithNoRecordTest extends CvsActivatedBorrowerLoggedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_Profil::getCurrentProfil()->setCfgModules(['recherche' => ['resultat' => []]]);
$this->dispatch('/Cvs_Plugin/search/index/expressionRecherche/Cuisson/page/2', true);
......@@ -267,7 +267,7 @@ class CvsNoticeAjaxControllerCvsSearchWithNoRecordTest extends CvsActivatedBorro
abstract class CvsSearchWithResultTestCase extends CvsActivatedBorrowerLoggedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_Profil::getCurrentProfil()
......@@ -287,7 +287,7 @@ abstract class CvsSearchWithResultTestCase extends CvsActivatedBorrowerLoggedTes
class CvsRecordsSearchCuissonTest extends CvsSearchWithResultTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$record = $this->fixture('Class_Notice',['id'=> 10,
......@@ -331,7 +331,7 @@ class CvsRecordsSearchCuissonTest extends CvsSearchWithResultTestCase {
class CvsWithRecordsSearchDelpyTest extends CvsSearchWithResultTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
$record = $this->fixture('Class_Notice',['id'=> 10,
......@@ -365,7 +365,7 @@ class CvsWithRecordsSearchDelpyTest extends CvsSearchWithResultTestCase {
class CvsRechercheControllerSimpleActionWithCvsActivatedTest extends CvsSearchWithResultTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_Profil::getCurrentProfil()
......@@ -407,7 +407,7 @@ class CvsRechercheControllerSimpleActionWithCvsActivatedTest extends CvsSearchWi
class CvsRechercheControllerSimpleActionWithCvsDeactivatedTest extends CvsSearchWithResultTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Cvs_BMKEY', '');
......@@ -439,7 +439,7 @@ class CvsRechercheControllerSimpleActionWithCvsDeactivatedTest extends CvsSearch
class CvsRechercheControllerSimpleActionWithCvsActivatedAndPreferencesHiddenTest extends CvsActivatedBorrowerLoggedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_Profil::getCurrentProfil()
......@@ -461,7 +461,7 @@ class CvsRechercheControllerSimpleActionWithCvsActivatedAndPreferencesHiddenTest
class CvsModulesControllerRechercheWithCVSActivateTest extends CvsActivatedAdminLoggedTestCase {
public function setup() {
public function setUp() : void {
parent::setup();
$this->dispatch('/admin/modules/recherche?config=site&type_module=recherche&id_profil=2&action1=resultat&action2=simple',
true);
......@@ -494,7 +494,7 @@ class CvsModulesControllerRechercheWithCVSActivatePostTest
protected $saved_preferences;
public function setup() {
public function setUp() : void {
parent::setup();
$this->postDispatch('/admin/modules/recherche?config=site&type_module=recherche&id_profil=2&action1=resultat&action2=simple',
......@@ -569,7 +569,7 @@ class CvsModulesControllerConfigRechercheResultatWithCvsDeactivatedTest
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$default_search_conf = array_filter((new Class_Systeme_ModulesAppli())->getValeursParDefaut('catalogue', ''));
......@@ -611,7 +611,7 @@ class CvsSearchWithDemoAccountTest extends CvsActivatedTestCase {
protected $_cvs;
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->clearIdentity();
......@@ -679,7 +679,7 @@ class CvsSearchWithJerryLoggedTest extends CvsActivatedTestCase {
$_result;
public function setUp() {
public function setUp() : void {
parent::setUp();
$jerry = $this->fixture('Class_Users',
......@@ -798,7 +798,7 @@ class CvsLinkWithBorrowerTest extends CvsActivatedTestCase {
$_result;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->fixture('Class_Bib',
......@@ -897,7 +897,7 @@ class CvsServiceWithBorrowerAndLibraryLabelTest extends CvsActivatedTestCase {
$_result;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Cvs_BMLABEL', 'Chinon-Vienne-Loire');
......@@ -997,7 +997,7 @@ class CvsSearchWithAnonymousAccessTest extends CvsActivatedTestCase {
protected $_cvs;
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->clearIdentity();
......@@ -1062,7 +1062,7 @@ class CvsSearchWithAnonymousAccessTest extends CvsActivatedTestCase {
class CvsSsoAnonymousAccessTest extends CvsActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('Cvs_ANONYMOUS_ACCESS', 1);
ZendAfi_Auth::getInstance()->clearIdentity();
......
......@@ -25,7 +25,7 @@ abstract class DiMusicActivatedTestCase extends AbstractControllerTestCase {
$_storm_default_to_volatile = true,
$_user;
public function setUp() {
public function setUp() : void {
parent::setUp();
Class_AdminVar::set('DiMusic_Id', 'Annecy');
......@@ -50,7 +50,7 @@ abstract class DiMusicActivatedTestCase extends AbstractControllerTestCase {
class DiMusicSsoTest extends DiMusicActivatedTestCase {
public function setUp() {
public function setUp() : void {
parent::setUp();
ZendAfi_Auth::getInstance()->logUser($this->_user);
$this->dispatch('/opac/modules/' . (new Class_DigitalResource())->getSsoActionForPlugin('DiMusic'), true);
......@@ -70,7 +70,7 @@ class DiMusicSsoTest extends DiMusicActivatedTestCase {
class DiMusicAdminBibnumTest extends Admin_AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->dispatch('/admin/bibnum', true);
}
......@@ -95,7 +95,7 @@ class DiMusicDashboardUnactivatedTest extends Admin_AbstractControllerTestCase {
protected $_storm_default_to_volatile = true;
public function setUp() {
public function setUp() : void {
parent::setUp();
$this->dispatch('/DiMusic_Plugin', true);