mirror of
https://github.com/Karaka-Management/Build.git
synced 2026-01-26 01:58:40 +00:00
get overall coverage to 76%
This commit is contained in:
parent
000bc81372
commit
1336578304
|
|
@ -34,8 +34,18 @@ foreach ($modules as $module) {
|
|||
continue;
|
||||
}
|
||||
|
||||
if (!\is_file(__DIR__ . '/../../Modules/' . $module . '/tests/Models/' . $model)) {
|
||||
echo $module . ': ' . $model . "\n";
|
||||
if (\stripos($model, '.php') === false) {
|
||||
throw \Exception('invalid substr');
|
||||
}
|
||||
|
||||
$model = \substr($model, 4, -4); // remove Null and .php from string
|
||||
|
||||
if (empty($model)) {
|
||||
throw \Exception('invalid substr');
|
||||
}
|
||||
|
||||
if (!\is_file(__DIR__ . '/../../Modules/' . $module . '/tests/Models/Null' . $model . 'Test.php')) {
|
||||
echo $module . ': Null' . $model . "\n";
|
||||
|
||||
if (!\is_dir(__DIR__ . '/../../Modules/' . $module . '/tests')) {
|
||||
\mkdir(__DIR__ . '/../../Modules/' . $module . '/tests');
|
||||
|
|
@ -45,8 +55,6 @@ foreach ($modules as $module) {
|
|||
\mkdir(__DIR__ . '/../../Modules/' . $module . '/tests/Models');
|
||||
}
|
||||
|
||||
$model = \substr($model, 4, -4); // remove Null and .php from string
|
||||
|
||||
$test = '<?php' . "\n"
|
||||
. '/**' . "\n"
|
||||
. ' * Orange Management' . "\n"
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user