Skip to content

Commit

Permalink
Fix EOL in log
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Feb 24, 2024
1 parent c79a476 commit a3c0c19
Showing 1 changed file with 11 additions and 13 deletions.
24 changes: 11 additions & 13 deletions test/phpunit/CommonClassTest.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@

use PHPUnit\Framework\TestCase;


/**
* Class for PHPUnit tests
*
Expand Down Expand Up @@ -80,10 +81,9 @@ public function __construct($name = null, array $data = array(), $dataName = '')
$this->savdb = $db;

if ((int) getenv('PHPUNIT_DEBUG') > 0) {
print get_called_class()." db->type=".$db->type." user->id=".$user->id;
print get_called_class()." db->type=".$db->type." user->id=".$user->id.PHP_EOL;
}
//print " - db ".$db->db;
print PHP_EOL;
}

/**
Expand Down Expand Up @@ -137,9 +137,8 @@ protected function onNotSuccessfulTest(Throwable $t): void
print "----- $className::$failedTestMethod failed - $argsText.".PHP_EOL;
print "Show last ".$nbLinesToShow." lines of dolibarr.log file -----".PHP_EOL;
foreach ($last_lines as $line) {
print $line . "<br>";
print $line.PHP_EOL;
}
print PHP_EOL;
print "----- end of dolibarr.log for $className::$failedTestMethod".PHP_EOL;

parent::onNotSuccessfulTest($t);
Expand Down Expand Up @@ -234,17 +233,17 @@ public static function tearDownAfterClass(): void
'cashdesk' => null,
'category' => 'Categorie',
'clicktodial' => 'ClickToDial',
'TBD_COLLAB' => 'Collab', // TODO: fill in proper name
'collab' => 'Collab', // TODO: fill in proper name
'comptabilite' => 'Comptabilite',
'contact' => null, // TODO: fill in proper class
'contract' => 'Contrat',
'cron' => 'Cron',
'datapolicy' => 'DataPolicy',
'TBD_DAV' => 'Dav', // TODO: fill in proper name
'dav' => 'Dav',
'debugbar' => 'DebugBar',
'delivery_note' => 'Expedition',
'deplacement' => 'Deplacement',
"TBD_DocGen" => 'DocumentGeneration', // TODO: fill in proper name
"documentgeneration" => 'DocumentGeneration', // TODO: fill in proper name
'don' => 'Don',
'dynamicprices' => 'DynamicPrices',
'ecm' => 'ECM',
Expand All @@ -253,12 +252,12 @@ public static function tearDownAfterClass(): void
'eventorganization' => 'EventOrganization',
'expensereport' => 'ExpenseReport',
'export' => 'Export',
'TBD_EXTERNALRSS' => 'ExternalRss', // TODO: fill in proper name
'externalrss' => 'ExternalRss', // TODO: fill in proper name
'externalsite' => 'ExternalSite',
'fckeditor' => 'Fckeditor',
'fournisseur' => 'Fournisseur',
'ftp' => 'FTP',
'TBD_GEOIPMAXMIND' => 'GeoIPMaxmind', // TODO: fill in proper name
'geoipmaxmind' => 'GeoIPMaxmind', // TODO: fill in proper name
'google' => null, // External ?
'gravatar' => 'Gravatar',
'holiday' => 'Holiday',
Expand All @@ -277,7 +276,6 @@ public static function tearDownAfterClass(): void
'mailmanspip' => 'MailmanSpip',
'margin' => 'Margin',
'member' => 'Adherent',
'member_type' => null, // TODO: External module ?
'memcached' => null, // TODO: External module?
'modulebuilder' => 'ModuleBuilder',
'mrp' => 'Mrp',
Expand All @@ -286,7 +284,7 @@ public static function tearDownAfterClass(): void
'mymodule' => null, // modMyModule - Name used in module builder (avoid false positives)
'notification' => 'Notification',
'numberwords' => null, // Not provided by default, no module tests
'TBD_OAUTH' => 'Oauth', // TODO: set proper name
'oauth' => 'Oauth',
'openstreetmap' => null, // External module?
'opensurvey' => 'OpenSurvey',
'order' => 'Commande',
Expand All @@ -296,7 +294,7 @@ public static function tearDownAfterClass(): void
'paypal' => 'Paypal',
'paypalplus' => null,
'prelevement' => 'Prelevement',
'TBD_PRINTING' => 'Printing', // TODO: set proper name
'printing' => 'Printing', // TODO: set proper name
'product' => 'Product',
'productbatch' => 'ProductBatch',
'productprice' => null,
Expand Down Expand Up @@ -326,7 +324,7 @@ public static function tearDownAfterClass(): void
'webhook' => 'Webhook',
'webportal' => 'WebPortal',
'webservices' => 'WebServices',
'TBD_WS_CLIENT' => 'WebServicesClient', // TODO: set proper name
'webservicesclient' => 'WebServicesClient', // TODO: set proper name
'website' => 'Website',
'workflow' => 'Workflow',
'workstation' => 'Workstation',
Expand Down

0 comments on commit a3c0c19

Please sign in to comment.