[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master da6d2cf 2/5: Enable valid tests that were not
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master da6d2cf 2/5: Enable valid tests that were not compilable with boost |
Date: |
Sun, 23 Apr 2017 15:37:31 -0400 (EDT) |
branch: master
commit da6d2cf02757856f67981c048f748904c9414592
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Enable valid tests that were not compilable with boost
In years past, 'boost/type_traits' headers were used instead of C++11's
<type_traits>. On 2017-01-07T11:41Z, the C++11 facility replaced the
less-capable boost implementation formerly used in 'value_cast.hpp',
rendering these tests compilable, but the tests were not updated at that
time. Now they have been updated, expanded, and reordered.
---
value_cast_test.cpp | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/value_cast_test.cpp b/value_cast_test.cpp
index 2d1619b..f686c87 100644
--- a/value_cast_test.cpp
+++ b/value_cast_test.cpp
@@ -64,14 +64,15 @@ int test_main(int, char*[])
BOOST_TEST(!is_string<char volatile*>::value);
BOOST_TEST(!is_string<char const volatile*>::value);
- BOOST_TEST(is_string<std::string >::value);
- BOOST_TEST(is_string<std::string &>::value);
- BOOST_TEST(is_string<std::string const >::value);
- BOOST_TEST(is_string<std::string const&>::value);
-
-// These tests fail to compile:
-// BOOST_TEST(is_string<std::string volatile >::value);
-// BOOST_TEST(is_string<std::string const volatile&>::value);
+ BOOST_TEST( is_string<std::string >::value);
+ BOOST_TEST( is_string<std::string const >::value);
+ BOOST_TEST(!is_string<std::string volatile >::value);
+ BOOST_TEST(!is_string<std::string const volatile >::value);
+
+ BOOST_TEST( is_string<std::string &>::value);
+ BOOST_TEST( is_string<std::string const &>::value);
+ BOOST_TEST(!is_string<std::string volatile&>::value);
+ BOOST_TEST(!is_string<std::string const volatile&>::value);
char const* ccp = "2.71828";
char* cp = const_cast<char*>("3.14159");