Skip to content
This repository was archived by the owner on Sep 10, 2021. It is now read-only.

Commit 2a57e61

Browse files
author
Michael Grauer
committed
BUG: Refs #212. Further testing cleanup and reorganization.
Removed the configs file for testing, removed the README as it is now obsolete, and reorganized the CMakeLists files to include some files that weren't tested. Also some style fixes in Executor.php
1 parent b4be277 commit 2a57e61

File tree

6 files changed

+32
-49
lines changed

6 files changed

+32
-49
lines changed

modules/batchmake/library/Executor.php

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,26 @@
1010
PURPOSE. See the above copyright notices for more information.
1111
=========================================================================*/
1212
include_once BASE_PATH . '/library/KWUtils.php';
13+
14+
/**
15+
* an executor class for the batchmake module, used to forward calls
16+
* to exec on to KWUtils.
17+
*/
1318
class Batchmake_Executor
1419
{
20+
/**
21+
* forwards a call to this method on to KWUtils.exec, with the same
22+
* method signature.
23+
* @param type $command
24+
* @param type $output
25+
* @param type $chdir
26+
* @param type $return_val
27+
*/
1528
public function exec($command, &$output = null, $chdir = "", &$return_val = null)
1629
{
17-
KWUtils::exec($command, $output, $chdir, $return_val);
30+
KWUtils::exec($command, $output, $chdir, $return_val);
1831
}
1932
} // end class
2033

21-
22-
34+
35+
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,21 @@
11
option( MIDAS_RUN_BATCHMAKE_TESTS "Should MIDAS run BatchMake tests? Specific configuration is required, see modules/batchmake/tests/README." )
22
if(MIDAS_RUN_BATCHMAKE_TESTS)
3+
# functionality tests will be added by the subdirectories
34
add_subdirectory( controllers )
5+
6+
# Style tests for code
7+
add_midas_style_test( StyleBatchmakeControllers ${CMAKE_SOURCE_DIR}/modules/batchmake/controllers )
8+
add_midas_style_test( StyleBatchmakeComponents ${CMAKE_SOURCE_DIR}/modules/batchmake/controllers/components )
9+
add_midas_style_test( StyleBatchmakeLibrary ${CMAKE_SOURCE_DIR}/modules/batchmake/library )
10+
add_midas_style_test( StyleBatchmakeModels ${CMAKE_SOURCE_DIR}/modules/batchmake/models )
11+
add_midas_style_test( StyleBatchmakeModelsBase ${CMAKE_SOURCE_DIR}/modules/batchmake/models/base )
12+
add_midas_style_test( StyleBatchmakeModelsDAO ${CMAKE_SOURCE_DIR}/modules/batchmake/models/dao )
13+
add_midas_style_test( StyleBatchmakeModelPDO ${CMAKE_SOURCE_DIR}/modules/batchmake/models/pdo )
14+
15+
16+
# Style tests for test code
417
add_midas_style_test( StyleTestsBatchmakeControllers ${CMAKE_SOURCE_DIR}/modules/batchmake/tests/controllers )
18+
add_midas_style_test( StyleTestsBatchmakeComponents ${CMAKE_SOURCE_DIR}/modules/batchmake/tests/controllers/components )
519
add_midas_style_test( StyleTestsBatchmakeLibrary ${CMAKE_SOURCE_DIR}/modules/batchmake/tests/library )
620
endif()
721

modules/batchmake/tests/README

Lines changed: 0 additions & 31 deletions
This file was deleted.

modules/batchmake/tests/configs/.gitignore

Lines changed: 0 additions & 4 deletions
This file was deleted.
Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
11
add_subdirectory( components )
22

3-
add_midas_test( BatchmakeConfigController ConfigControllerTest.php )
4-
5-
# Style
6-
add_midas_style_test( StyleBatchmakeControllers ${CMAKE_SOURCE_DIR}/modules/batchmake/controllers )
7-
add_midas_style_test( StyleTestsBatchmakeComponents ${CMAKE_SOURCE_DIR}/modules/batchmake/tests/controllers/components )
3+
add_midas_test( BatchmakeConfigController ConfigControllerTest.php )
Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1 @@
1-
2-
3-
add_midas_test( KWBatchmakeComponent KWBatchmakeComponentTest.php )
4-
5-
# Style
6-
add_midas_style_test( StyleBatchmakeComponents ${CMAKE_SOURCE_DIR}/modules/batchmake/controllers/components )
1+
add_midas_test( KWBatchmakeComponent KWBatchmakeComponentTest.php )

0 commit comments

Comments
 (0)