From b9fb3c96953ef133775993ff39cde867aa05e61c Mon Sep 17 00:00:00 2001 From: Martchus Date: Thu, 17 Aug 2017 18:40:34 +0200 Subject: [PATCH] Move test helper in its own namespace --- tests/helper.cpp | 4 ++++ tests/helper.h | 4 ++++ tests/overall.h | 3 ++- tests/tagvalue.cpp | 1 + 4 files changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/helper.cpp b/tests/helper.cpp index dfc259b..392cfdc 100644 --- a/tests/helper.cpp +++ b/tests/helper.cpp @@ -1,5 +1,7 @@ #include "./helper.h" +namespace TestUtilities { + /*! * \brief Prints a TagTextEncoding to enable CPPUNIT_ASSERT_EQUAL for tag values. */ @@ -20,3 +22,5 @@ std::ostream &operator <<(std::ostream &os, const Media::TagTextEncoding &encodi } return os; } + +} diff --git a/tests/helper.h b/tests/helper.h index 3074197..bf3f809 100644 --- a/tests/helper.h +++ b/tests/helper.h @@ -2,9 +2,12 @@ #define TAGPARSER_TEST_HELPER #include "../tagvalue.h" +#include "../notification.h" #include +namespace TestUtilities { + std::ostream &operator <<(std::ostream &os, const Media::TagTextEncoding &encoding); /*! @@ -23,5 +26,6 @@ inline std::ostream &operator <<(std::ostream &os, const Media::PositionInSet &p return os << pos.toString(); } +} #endif // TAGPARSER_TEST_HELPER diff --git a/tests/overall.h b/tests/overall.h index 692799b..6dc7141 100644 --- a/tests/overall.h +++ b/tests/overall.h @@ -4,8 +4,9 @@ #include "../mediafileinfo.h" #include "../tagvalue.h" -#include #include +#include +using namespace TestUtilities; #include #include diff --git a/tests/tagvalue.cpp b/tests/tagvalue.cpp index 85a9ac1..c92fd52 100644 --- a/tests/tagvalue.cpp +++ b/tests/tagvalue.cpp @@ -5,6 +5,7 @@ #include #include +using namespace TestUtilities; #include #include