[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 2cbcddd 6/6: Test auxiliary functions with ty
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 2cbcddd 6/6: Test auxiliary functions with type bool too |
Date: |
Sun, 30 Apr 2017 11:49:37 -0400 (EDT) |
branch: master
commit 2cbcddd1ac8d3752412b6a180e747a75f4c5425d
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Test auxiliary functions with type bool too
---
tn_range_test.cpp | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/tn_range_test.cpp b/tn_range_test.cpp
index 0d099ec..5d115a4 100644
--- a/tn_range_test.cpp
+++ b/tn_range_test.cpp
@@ -137,8 +137,10 @@ void tn_range_test::test_auxiliary_functions(char const*
file, int line)
T const minT = std::numeric_limits<T>::lowest();
INVOKE_BOOST_TEST(!is_strictly_between_extrema(maxT), file, line);
- // This test would fail for type bool.
- INVOKE_BOOST_TEST( is_strictly_between_extrema<T>(1), file, line);
+ if(1 < maxT)
+ {
+ INVOKE_BOOST_TEST( is_strictly_between_extrema<T>(1), file, line);
+ }
INVOKE_BOOST_TEST_EQUAL( 0, signum(T( 0)), file, line);
INVOKE_BOOST_TEST_EQUAL( 1, signum(T( 1)), file, line);
@@ -291,6 +293,7 @@ void tn_range_test::test_percentages(char const* file, int
line)
void tn_range_test::test()
{
+ test_auxiliary_functions<bool >(__FILE__, __LINE__);
test_auxiliary_functions<signed char >(__FILE__, __LINE__);
test_auxiliary_functions<unsigned char>(__FILE__, __LINE__);
test_auxiliary_functions<int >(__FILE__, __LINE__);
- [lmi-commits] [lmi] master updated (f306a7d -> 2cbcddd), Greg Chicares, 2017/04/30
- [lmi-commits] [lmi] master 2faa024 5/6: Test auxiliary functions with an unsigned type too, Greg Chicares, 2017/04/30
- [lmi-commits] [lmi] master eab8e30 4/6: Improve signum(), Greg Chicares, 2017/04/30
- [lmi-commits] [lmi] master 1484727 1/6: Remove emulation of std::isnan(), Greg Chicares, 2017/04/30
- [lmi-commits] [lmi] master eb921be 3/6: Fix peccable unit tests, Greg Chicares, 2017/04/30
- [lmi-commits] [lmi] master 2cbcddd 6/6: Test auxiliary functions with type bool too,
Greg Chicares <=
- [lmi-commits] [lmi] master 3718824 2/6: Improve interest-conversion example, Greg Chicares, 2017/04/30