Browse Source

Remove test output verbosity

Laurent Destailleur 2 years ago
parent
commit
f76405d01a
2 changed files with 3 additions and 2 deletions
  1. 2 1
      test/phpunit/LangTest.php
  2. 1 1
      test/phpunit/SecurityTest.php

+ 2 - 1
test/phpunit/LangTest.php

@@ -212,13 +212,14 @@ class LangTest extends PHPUnit\Framework\TestCase
 
 			unset($tmplangs);
 
+			print "Check also some syntax rules into the language file\n";
 			$filesarray2 = scandir(DOL_DOCUMENT_ROOT.'/langs/'.$code);
 			foreach ($filesarray2 as $key => $file) {
 				if (! preg_match('/\.lang$/', $file)) {
 					continue;
 				}
 
-				print 'Check lang file '.$file."\n";
+				//print 'Check lang file '.$file."\n";
 				$filecontent=file_get_contents(DOL_DOCUMENT_ROOT.'/langs/'.$code.'/'.$file);
 
 				$result=preg_match('/=--$/m', $filecontent);	// A special % char we don't want. We want the common one.

+ 1 - 1
test/phpunit/SecurityTest.php

@@ -782,7 +782,7 @@ class SecurityTest extends PHPUnit\Framework\TestCase
 		$url = 'https://www.dolibarr.fr';	// This is a redirect 301 page
 		$tmp = getURLContent($url, 'GET', '', 0);	// We do NOT follow
 		print __METHOD__." url=".$url."\n";
-		$this->assertEquals(301, $tmp['http_code'], 'Should GET url 301 without a follow -> 301');
+		$this->assertEquals(301, $tmp['http_code'], 'Should GET url 301 response and stop here');
 
 		$url = 'https://www.dolibarr.fr';	// This is a redirect 301 page
 		$tmp = getURLContent($url);		// We DO follow a page with return 300 so result should be 200