From 1b25fdc3237c228b53a5d20ed3a60c93ac549159 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur <eldy@destailleur.fr> Date: Thu, 8 May 2014 18:09:39 +0200 Subject: [PATCH] Fix: Param at wrong place. Fix: Add warning if phpunit are runned with external module on. --- .../invoices/email_unpaid_invoices_to_representatives.php | 2 +- test/phpunit/AllTests.php | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/invoices/email_unpaid_invoices_to_representatives.php b/scripts/invoices/email_unpaid_invoices_to_representatives.php index e83dbe5b795..c0e04c0efef 100755 --- a/scripts/invoices/email_unpaid_invoices_to_representatives.php +++ b/scripts/invoices/email_unpaid_invoices_to_representatives.php @@ -226,7 +226,7 @@ function envoi_mail($mode,$oldemail,$message,$total,$userlang,$oldsalerepresenta $allmessage.= $newlangs->transnoentities("NoteListOfYourUnpaidInvoices").($usehtml?"<br>\n":"\n"); } $allmessage.= $message.($usehtml?"<br>\n":"\n"); - $allmessage.= $langs->trans("Total")." = ".price($total,0,0,-1,$conf->currency).($usehtml?"<br>\n":"\n"); + $allmessage.= $langs->trans("Total")." = ".price($total,0,$newlangs,0,0,-1,$conf->currency).($usehtml?"<br>\n":"\n"); if (! empty($conf->global->SCRIPT_EMAIL_UNPAID_INVOICES_SALESREPRESENTATIVES_FOOTER)) { $allmessage.=$conf->global->SCRIPT_EMAIL_UNPAID_INVOICES_SALESREPRESENTATIVES_FOOTER; diff --git a/test/phpunit/AllTests.php b/test/phpunit/AllTests.php index f9bae36a568..0b7b09d199e 100644 --- a/test/phpunit/AllTests.php +++ b/test/phpunit/AllTests.php @@ -36,7 +36,10 @@ if ($langs->defaultlang != 'en_US') print "Error: Default language for company to run tests must be set to en_US or auto. Current is ".$langs->defaultlang."\n"; exit; } - +if (! empty($conf->google->enabled)) +{ + print "Warning: Google module should not be enabled.\n"; +} if (empty($user->id)) { print "Load permissions for admin user nb 1\n"; -- GitLab