/*
- * Copyright (c) 2000 - 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ * Copyright (c) 2000 - 2020 Samsung Electronics Co., Ltd All Rights Reserved
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
#define Stringify(...) \
(static_cast<std::ostringstream &>(std::ostringstream() \
STRINGIFY_(PP_NARG(__VA_ARGS__), __VA_ARGS__))).str()
-
-#define StringifyAvoid(...) std::string()
-#define StringifyError(...) Stringify(__VA_ARGS__)
-
-#ifdef DEBUG
-#define StringifyDebug(...) Stringify(__VA_ARGS__)
-#else
-#define StringifyDebug(...) std::string()
-#endif
BOOST_AUTO_TEST_SUITE(STRINGIFY_TEST)
-POSITIVE_TEST_CASE(stringify_default)
+POSITIVE_TEST_CASE(stringify)
{
BOOST_REQUIRE(Stringify("a", "b", "c") == "abc");
BOOST_REQUIRE(Stringify(std::string("a"), "b", "c") == "abc");
BOOST_REQUIRE(Stringify().empty());
}
-POSITIVE_TEST_CASE(stringify_avoid)
-{
- BOOST_REQUIRE(StringifyAvoid("a", "b", "c").empty());
- BOOST_REQUIRE(StringifyAvoid(std::string("a"), "b", "c").empty());
- BOOST_REQUIRE(StringifyAvoid().empty());
-}
-
-POSITIVE_TEST_CASE(stringify_error)
-{
- BOOST_REQUIRE(StringifyError("a", "b", "c") == "abc");
- BOOST_REQUIRE(StringifyError(std::string("a"), "b", "c") == "abc");
- BOOST_REQUIRE(StringifyError().empty());
-}
-
BOOST_AUTO_TEST_SUITE_END()