Skip to content

Commit

Permalink
update r736
Browse files Browse the repository at this point in the history
  • Loading branch information
srz-zumix committed Nov 4, 2014
1 parent 5255d6c commit 8a8b100
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 8 deletions.
2 changes: 1 addition & 1 deletion doc/Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ PROJECT_NAME = iutest
# could be handy for archiving the generated documentation or if some version
# control system is used.

PROJECT_NUMBER = 1.10.99.34
PROJECT_NUMBER = 1.10.99.35

# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
Expand Down
4 changes: 2 additions & 2 deletions include/iutest_typed_tests.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ class TypedTestCasePState
if( m_names != NULL )
{
IUTEST_LOG_(WARNING) << detail::FormatCompilerIndependentFileLocation(file, line)
<< " Test " << test_name << " must be defined before IUTEST_REGISTER_TYPED_TEST_CASE_P("
<< ": Test " << test_name << " must be defined before IUTEST_REGISTER_TYPED_TEST_CASE_P("
<< testcase_name << ", ...).\n";
}
#if IUTEST_TYPED_TEST_P_STRICT
Expand All @@ -369,7 +369,7 @@ class TypedTestCasePState
}
}
IUTEST_LOG_(WARNING) << detail::FormatCompilerIndependentFileLocation(file, line)
<< ": " << test_name << " Test has not been registered.\n";
<< ": Test " << test_name << " has not been registered.\n";
ret = false;
}
return ret;
Expand Down
4 changes: 2 additions & 2 deletions include/iutest_ver.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@

//======================================================================
// define
#define IUTEST_VER 0x01109934u //!< iutest version 1.10.99.34
#define IUTEST_VER 0x01109935u //!< iutest version 1.10.99.35
#define IUTEST_MAJORVER 0x01u //!< Major Version
#define IUTEST_MINORVER 0x10u //!< Minor Version
#define IUTEST_BUILD 0x99u //!< Build
#define IUTEST_REVISION 0x34u //!< Revision
#define IUTEST_REVISION 0x35u //!< Revision

/**
* @mainpage
Expand Down
26 changes: 23 additions & 3 deletions test/iutest_type_param_tests_strict.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ ::iutest::detail::IUStreamCapture stderr_capture(stderr);

#endif

#if IUTEST_HAS_TYPED_TEST_P && IUTEST_TYPED_TEST_P_STRICT
#if IUTEST_HAS_TYPED_TEST_P

#if IUTEST_TYPED_TEST_P_STRICT

template<typename T>
class VerifyFailTypeParamTest : public ::iutest::Test {};
Expand All @@ -40,6 +42,20 @@ IUTEST_REGISTER_TYPED_TEST_CASE_P(VerifyFailTypeParamTest, A);

IUTEST_INSTANTIATE_TYPED_TEST_CASE_P(A, VerifyFailTypeParamTest, ::iutest::Types<int>);

#endif

template<typename T>
class RegisterFailTypeParamTest : public ::iutest::Test {};

IUTEST_TYPED_TEST_CASE_P(RegisterFailTypeParamTest);
IUTEST_TYPED_TEST_P(RegisterFailTypeParamTest, A)
{
}
IUTEST_REGISTER_TYPED_TEST_CASE_P(RegisterFailTypeParamTest, A);

IUTEST_TYPED_TEST_P(RegisterFailTypeParamTest, B)
{
}

#endif

Expand All @@ -50,11 +66,15 @@ int main(int argc, char* argv[])
#endif
{
IUTEST_INIT(&argc, argv);
#if IUTEST_HAS_TYPED_TEST_P && IUTEST_TYPED_TEST_P_STRICT && IUTEST_HAS_STREAMCAPTURE
IUTEST_EXPECT_STRIN("B Test has not been registered.", stderr_capture.GetStreamString());
#if IUTEST_HAS_TYPED_TEST_P && IUTEST_HAS_STREAMCAPTURE
#if IUTEST_TYPED_TEST_P_STRICT
IUTEST_EXPECT_STRIN("Test B has not been registered.", stderr_capture.GetStreamString());
#endif
IUTEST_EXPECT_STRIN("Test B must be defined before IUTEST_REGISTER_TYPED_TEST_CASE_P(RegisterFailTypeParamTest, ...).", stderr_capture.GetStreamString());
#endif
if( IUTEST_RUN_ALL_TESTS() ) return 1;

printf("*** Successful ***\n");
return 0;
}

0 comments on commit 8a8b100

Please sign in to comment.