From 0d95d58f8b6259e06e391ce962ec2062260bcdb8 Mon Sep 17 00:00:00 2001 From: Milo Yip Date: Sat, 13 Jan 2018 12:37:01 +0800 Subject: [PATCH] Try to fix travis build --- test/unittest/namespacetest.cpp | 4 ++++ test/unittest/unittest.h | 2 ++ 2 files changed, 6 insertions(+) diff --git a/test/unittest/namespacetest.cpp b/test/unittest/namespacetest.cpp index 1814724..9f5c9af 100644 --- a/test/unittest/namespacetest.cpp +++ b/test/unittest/namespacetest.cpp @@ -12,6 +12,10 @@ // CONDITIONS OF ANY KIND, either express or implied. See the License for the // specific language governing permissions and limitations under the License. +// Not throwing exception for this test +#include +#define RAPIDJSON_ASSERT(x) assert(x) + #include "unittest.h" // test another instantiation of RapidJSON in a different namespace diff --git a/test/unittest/unittest.h b/test/unittest/unittest.h index aa091aa..4b1c293 100644 --- a/test/unittest/unittest.h +++ b/test/unittest/unittest.h @@ -117,7 +117,9 @@ public: #pragma GCC diagnostic pop #endif +#ifndef RAPIDJSON_ASSERT #define RAPIDJSON_ASSERT(x) (!(x) ? throw AssertException(RAPIDJSON_STRINGIFY(x)) : (void)0u) +#endif class Random { public: