mirror of
https://github.com/catchorg/Catch2.git
synced 2025-05-23 13:09:28 +00:00
Marked tests that use C++11 features with [c++11] tag and exclude them from approval tests
This commit is contained in:
parent
976a655496
commit
1ae84897d4
9 changed files with 22 additions and 352 deletions
|
@ -7,7 +7,7 @@
|
|||
#pragma clang diagnostic ignored "-Wc++98-compat"
|
||||
#endif
|
||||
|
||||
TEST_CASE( "tuple<>", "[toString][tuple]" )
|
||||
TEST_CASE( "tuple<>", "[toString][tuple][c++11][.]" )
|
||||
{
|
||||
typedef std::tuple<> type;
|
||||
CHECK( "{ }" == Catch::toString(type{}) );
|
||||
|
@ -15,27 +15,27 @@ TEST_CASE( "tuple<>", "[toString][tuple]" )
|
|||
CHECK( "{ }" == Catch::toString(value) );
|
||||
}
|
||||
|
||||
TEST_CASE( "tuple<int>", "[toString][tuple]" )
|
||||
TEST_CASE( "tuple<int>", "[toString][tuple][c++11][.]" )
|
||||
{
|
||||
typedef std::tuple<int> type;
|
||||
CHECK( "{ 0 }" == Catch::toString(type{0}) );
|
||||
}
|
||||
|
||||
|
||||
TEST_CASE( "tuple<float,int>", "[toString][tuple]" )
|
||||
TEST_CASE( "tuple<float,int>", "[toString][tuple][c++11][.]" )
|
||||
{
|
||||
typedef std::tuple<float,int> type;
|
||||
CHECK( "1.2f" == Catch::toString(float(1.2)) );
|
||||
CHECK( "{ 1.2f, 0 }" == Catch::toString(type{1.2,0}) );
|
||||
}
|
||||
|
||||
TEST_CASE( "tuple<string,string>", "[toString][tuple]" )
|
||||
TEST_CASE( "tuple<string,string>", "[toString][tuple][c++11][.]" )
|
||||
{
|
||||
typedef std::tuple<std::string,std::string> type;
|
||||
CHECK( "{ \"hello\", \"world\" }" == Catch::toString(type{"hello","world"}) );
|
||||
}
|
||||
|
||||
TEST_CASE( "tuple<tuple<int>,tuple<>,float>", "[toString][tuple]" )
|
||||
TEST_CASE( "tuple<tuple<int>,tuple<>,float>", "[toString][tuple][c++11][.]" )
|
||||
{
|
||||
typedef std::tuple<std::tuple<int>,std::tuple<>,float> type;
|
||||
type value { std::tuple<int>{42}, {}, 1.2f };
|
||||
|
@ -43,7 +43,7 @@ TEST_CASE( "tuple<tuple<int>,tuple<>,float>", "[toString][tuple]" )
|
|||
}
|
||||
|
||||
#ifdef CATCH_CONFIG_CPP11_NULLPTR
|
||||
TEST_CASE( "tuple<nullptr,int,const char *>", "[toString][tuple]" )
|
||||
TEST_CASE( "tuple<nullptr,int,const char *>", "[toString][tuple][c++11][.]" )
|
||||
{
|
||||
typedef std::tuple<std::nullptr_t,int,const char *> type;
|
||||
type value { nullptr, 42, "Catch me" };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue