1 /*=========================================================================
3 Program: Insight Segmentation & Registration Toolkit
4 Module: $RCSfile: ctest.h,v $
6 Date: $Date: 2002-10-09 02:54:24 $
7 Version: $Revision: 1.13 $
9 Copyright (c) 2002 Insight Consortium. All rights reserved.
10 See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
12 This software is distributed WITHOUT ANY WARRANTY; without even
13 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 PURPOSE. See the above copyright notices for more information.
16 =========================================================================*/
19 #include "cmStandardIncludes.h"
25 * Initialize and finalize testing
31 * Process the tests. This is the main routine. The execution of the
32 * tests should look like this:
36 * // Set some things on foo
43 * Try to build the project
48 * Try to run tests of the project
53 * Do revision control update of directory
55 int UpdateDirectory();
58 * Do configure the project
60 int ConfigureDirectory();
63 * Run the test for a directory and any subdirectories
65 void ProcessDirectory(std::vector
<std::string
> &passed
,
66 std::vector
<std::string
> &failed
);
69 * Find the executable for a test
71 std::string
FindExecutable(const char *exe
);
76 bool SetTest(const char*);
83 bool m_UseIncludeRegExp
;
84 std::string m_IncludeRegExp
;
86 bool m_UseExcludeRegExp
;
87 bool m_UseExcludeRegExpFirst
;
88 std::string m_ExcludeRegExp
;
90 std::string m_ConfigType
;
107 struct cmCTestTestResult
111 std::string m_FullCommandLine
;
112 double m_ExecutionTime
;
114 std::string m_CompletionStatus
;
115 std::string m_Output
;
118 struct cmCTestBuildErrorWarning
123 std::string m_SourceFile
;
124 std::string m_SourceFileTail
;
126 std::string m_PreContext
;
127 std::string m_PostContext
;
130 typedef std::vector
<cmCTestTestResult
> tm_TestResultsVector
;
131 typedef std::map
<std::string
, std::string
> tm_DartConfigurationMap
;
133 tm_TestResultsVector m_TestResults
;
134 std::string m_ToplevelPath
;
135 tm_DartConfigurationMap m_DartConfiguration
;
136 int m_Tests
[LAST_TEST
];
138 std::string m_CurrentTag
;
140 std::string m_StartBuild
;
141 std::string m_EndBuild
;
142 std::string m_StartTest
;
143 std::string m_EndTest
;
146 * Generate the Dart compatible output
148 void GenerateDartOutput(std::ostream
& os
);
149 void GenerateDartBuildOutput(std::ostream
& os
,
150 std::vector
<cmCTestBuildErrorWarning
>);