gnucash unstable: Fix travis test failure: It seems the boost bug is fixed.

John Ralls jralls at code.gnucash.org
Sun Jan 7 19:46:39 EST 2018


Updated	 via  https://github.com/Gnucash/gnucash/commit/502001cd (commit)
	from  https://github.com/Gnucash/gnucash/commit/edf17ab2 (commit)



commit 502001cd7ca8c3d14b01a15e755694b7ef1d899a
Author: John Ralls <jralls at ceridwen.us>
Date:   Sun Jan 7 16:46:25 2018 -0800

    Fix travis test failure: It seems the boost bug is fixed.

diff --git a/libgnucash/engine/test/test-gnc-guid.cpp b/libgnucash/engine/test/test-gnc-guid.cpp
index b188c7c..e164662 100644
--- a/libgnucash/engine/test/test-gnc-guid.cpp
+++ b/libgnucash/engine/test/test-gnc-guid.cpp
@@ -30,6 +30,7 @@
 #include <string>
 #include <iostream>
 #include <gtest/gtest.h>
+#include <boost/version.hpp>
 
 TEST (GncGUID, creation)
 {
@@ -82,8 +83,10 @@ TEST (GncGUID, from_string)
     }
     /* Currently, boost uuid string parsing is mostly very permissive, but it has some
      * odd pet peves. See https://svn.boost.org/trac/boost/ticket/12253 for more.*/
-    //EXPECT_TRUE (fail) << "Parsing the bogus string should throw";
-    EXPECT_FALSE (fail) << "Perhaps boost uuid is fixed.";
+    if (BOOST_VERSION >= 106600)
+        EXPECT_TRUE (fail) << "Parsing the bogus string should throw";
+    else
+        EXPECT_FALSE (fail) << "Perhaps boost uuid is fixed.";
 }
 
 TEST (GncGUID, round_trip)



Summary of changes:
 libgnucash/engine/test/test-gnc-guid.cpp | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)



More information about the gnucash-changes mailing list