forked from Wavyzz/dolibarr
Enhance sql quality. Refused double quotes into sql content.
This commit is contained in:
@@ -160,6 +160,10 @@ class CodingSqlTest extends PHPUnit_Framework_TestCase
|
||||
print __METHOD__." Result for checking we don't have back quote = ".$result."\n";
|
||||
$this->assertTrue($result===false, 'Found back quote into '.$file.'. Bad.');
|
||||
|
||||
$result=strpos($filecontent,'"');
|
||||
print __METHOD__." Result for checking we don't have double quote = ".$result."\n";
|
||||
$this->assertTrue($result===false, 'Found double quote into '.$file.'. Bad.');
|
||||
|
||||
$result=strpos($filecontent,'int(');
|
||||
print __METHOD__." Result for checking we don't have 'int(' instead of 'integer' = ".$result."\n";
|
||||
$this->assertTrue($result===false, 'Found int(x) or tinyint(x) instead of integer or tinyint into '.$file.'. Bad.');
|
||||
|
||||
Reference in New Issue
Block a user