15 #ifndef INCG_IRIS_IUTEST_CORE_IMPL_HPP_D5ABC7DE_C751_4AC0_922F_547880163891_
16 #define INCG_IRIS_IUTEST_CORE_IMPL_HPP_D5ABC7DE_C751_4AC0_922F_547880163891_
23 #include "../iutest_suite.hpp"
35 #if IUTEST_USE_OWN_LIST
36 typedef detail::iu_list<TestSuite> iuTestSuites;
38 typedef ::std::vector<TestSuite*> iuTestSuites;
40 typedef ::std::vector<Environment*> iuEnvironmentList;
42 UnitTestImpl() : m_total_test_num(0), m_disable_num(0), m_should_run_num(0)
43 , m_current_testsuite(NULL), m_elapsedmsec(0)
47 ~UnitTestImpl() { TerminateImpl(); }
53 static TestResult* current_test_result();
62 static bool ValidateTestPropertyName(const ::std::string& name)
65 "name",
"tests",
"failures",
"disabled",
"skip",
"errors",
"time",
"timestamp",
"random_seed"
67 #if !defined(IUTEST_NO_FUNCTION_TEMPLATE_ORDERING)
77 TestSuite* AddTestSuite(const ::std::string& testsuite_name,
TestTypeId id
83 p =
new T (testsuite_name,
id, setup, teardown);
84 m_testsuites.push_back(p);
89 void AddTestInfo(TestSuite* pCase, TestInfo* pInfo);
91 static bool SkipTest();
102 int ListupWithWhere()
const;
112 void ClearNonAdHocTestResult();
117 void ClearAdHocTestResult()
119 m_ad_hoc_testresult.Clear();
126 static void RecordProperty(
const TestProperty& prop);
136 bool DoInfoOptions();
142 void InitializeImpl();
146 void TerminateImpl();
149 #if IUTEST_HAS_INVALID_PARAMETER_HANDLER
151 IUTEST_PRAGMA_CRT_SECURE_WARN_DISABLE_BEGIN()
155 , const
wchar_t * file,
unsigned int line, uintptr_t pReserved);
157 IUTEST_PRAGMA_CRT_SECURE_WARN_DISABLE_END()
164 static UnitTestImpl* ptr = NULL;
168 friend class UnitTestSource;
169 friend class Test::TestRecordPropertyHelper;
171 int m_total_test_num;
173 int m_should_run_num;
174 TestSuite* m_current_testsuite;
176 iuTestSuites m_testsuites;
177 TestResult m_ad_hoc_testresult;
187 ::std::string MakeIndexName(
size_t index);
194 ::std::string MakeIndexTestName(
const char* basename,
size_t index);
201 ::std::string MakeParamTestName(const ::std::string& basename, const ::std::string& parame_name);
209 ::std::string MakeIndexTypedTestName(
const char* basename,
size_t index)
212 ::std::string name = MakeIndexTestName(basename, index);
214 name += GetTypeNameProxy<T>::GetTypeNameProxy();
217 return MakeIndexTestName(basename, index);
227 ::std::string MakePrefixedIndexTestName(
const char* prefix,
const char* basename,
size_t index);
236 ::std::string MakePrefixedIndexTypedTestName(
const char* prefix,
const char* basename,
size_t index)
239 ::std::string name = prefix;
244 name += MakeIndexTypedTestName<T>(basename, index);
247 return MakePrefixedIndexTestName(prefix, basename, index);
256 # include "../impl/iutest_core_impl.ipp"
static bool ValidateName(const ::std::string &name, Ite begin, Ite end)
有効なキーかどうかチェック
Definition: iutest_result.hpp:193
#define IUTEST_CXX_NOEXCEPT_SPEC
noexcept specification definition
Definition: iutest_compiler.hpp:811
#define IUTEST_ATTRIBUTE_NORETURN_
noreturn
Definition: iutest_compiler.hpp:1433
iris unit test internal definition
iris unit test commandline option message
iutest root namespace
Definition: iutest_charcode.hpp:33
detail::type_least_t< 8 >::UInt TimeInMillisec
ミリ秒単位を扱う型
Definition: iutest_defs.hpp:526
void(* SetUpMethod)()
SetUp 関数型
Definition: iutest_defs.hpp:523
void(* TearDownMethod)()
TearDown 関数型
Definition: iutest_defs.hpp:524
internal::TypeId TestTypeId
テスト識別型
Definition: iutest_defs.hpp:521
const ::iutest::TestSuite * FindTestSuite(const char *testsuite_name)
TestSuite の検索
Definition: iutest_util_tests.hpp:220