1 #ifndef _GLCTESTRUNNER_HPP
2 #define _GLCTESTRUNNER_HPP
3 /*-------------------------------------------------------------------------
4 * OpenGL Conformance Test Suite
5 * -----------------------------
7 * Copyright (c) 2016 Google Inc.
8 * Copyright (c) 2016 The Khronos Group Inc.
10 * Licensed under the Apache License, Version 2.0 (the "License");
11 * you may not use this file except in compliance with the License.
12 * You may obtain a copy of the License at
14 * http://www.apache.org/licenses/LICENSE-2.0
16 * Unless required by applicable law or agreed to in writing, software
17 * distributed under the License is distributed on an "AS IS" BASIS,
18 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 * See the License for the specific language governing permissions and
20 * limitations under the License.
25 */ /*-------------------------------------------------------------------*/
27 #include "gluPlatform.hpp"
28 #include "tcuDefs.hpp"
48 const char* configName;
49 const char* glConfigName;
50 const char* screenRotation;
52 const char* fboConfig;
59 std::vector<std::string> args;
60 std::string logFilename;
63 // Conformance test run summary - written to cts-run-summary.xml
68 std::string configLogFilename;
69 std::vector<TestRunParams> runParams;
71 TestRunSummary(void) : isConformant(false)
77 runType = glu::ApiType();
79 configLogFilename.clear();
91 VERBOSE_COMMANDS = (1 << 0),
92 VERBOSE_IMAGES = (1 << 1),
93 VERBOSE_SHADERS = (1 << 2),
95 VERBOSE_ALL = VERBOSE_COMMANDS | VERBOSE_IMAGES,
97 PRINT_SUMMARY = (1 << 3)
100 TestRunner(tcu::Platform& platform, tcu::Archive& archive, const char* logDirPath, glu::ApiType type,
107 TestRunner(const TestRunner& other);
108 TestRunner operator=(const TestRunner& other);
113 void initSession(const TestRunParams& runParams);
114 void deinitSession(void);
115 bool iterateSession(void);
119 ITERATE_INIT = 0, //!< Call init() on this iteration.
120 ITERATE_DEINIT, //!< Call deinit() on this iteration.
122 ITERATE_INIT_SESSION, //!< Init current session.
123 ITERATE_DEINIT_SESSION, //!< Deinit session and move to next.
124 ITERATE_ITERATE_SESSION, //!< Iterate current session.
129 tcu::Platform& m_platform;
130 tcu::Archive& m_archive;
131 std::string m_logDirPath;
136 IterateState m_iterState;
137 std::vector<TestRunParams> m_runSessions;
138 std::vector<TestRunParams>::const_iterator m_sessionIter;
139 RunSession* m_curSession;
142 int m_sessionsExecuted;
143 int m_sessionsPassed;
144 int m_sessionsFailed;
145 TestRunSummary m_summary;
150 #endif // _GLCTESTRUNNER_HPP