Fix phpunit

This commit is contained in:
Laurent Destailleur 2017-05-21 21:04:20 +02:00
parent ff35229be5
commit 3e381aa5a2
2 changed files with 5 additions and 3 deletions

View File

@ -83,7 +83,9 @@ class AdherentTest extends PHPUnit_Framework_TestCase
print "\n".__METHOD__." Company must be setup to have name-firstname in order 'Firstname Lastname'\n";
die();
}
if (! empty($conf->global->MAIN_MODULE_LDAP)) { print "\n".__METHOD__." module LDAP must be disabled.\n"; die(); }
if (! empty($conf->global->MAIN_MODULE_MAILMANSPIP)) { print "\n".__METHOD__." module MailmanSpip must be disabled.\n"; die(); }
print __METHOD__."\n";
}
@ -322,7 +324,7 @@ class AdherentTest extends PHPUnit_Framework_TestCase
$expected = DOL_MAIN_URL_ROOT.','.$localobject->id.',,New firstname,New name,New firstname New name,'.
'New company,New address,New zip,New town,Belgium,newemail@newemail.com,'.dol_print_date($localobject->birth,'day').',,'.
'newlogin,dolibspec,New firstname,New name,New company,New address,New zip,New town,Belgium';
'newlogin,,New firstname,New name,New company,New address,New zip,New town,Belgium';
$result = $localobject->makeSubstitution($template);
print __METHOD__." result=".$result."\n";

View File

@ -76,7 +76,7 @@ class UserTest extends PHPUnit_Framework_TestCase
{
global $conf,$user,$langs,$db;
if (! empty($conf->global->MAIN_LDAP_ENABLED)) { print "\n".__METHOD__." module LDAP must be disabled.\n"; die(); }
if (! empty($conf->global->MAIN_MODULE_LDAP)) { print "\n".__METHOD__." module LDAP must be disabled.\n"; die(); }
$db->begin(); // This is to have all actions inside a transaction even if test launched without suite.