summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-07-11 21:53:04 +0300
committerAndrei Karas <akaras@inbox.ru>2017-07-11 21:53:04 +0300
commit8ca1f3d1666b8dc710af2b216c8ce71ecc2ac471 (patch)
tree35334434f931a50df1232771b49d54b04179193e
parent71485eae058bab256770e90e5de196b3baf01cea (diff)
downloadplus-8ca1f3d1666b8dc710af2b216c8ce71ecc2ac471.tar.gz
plus-8ca1f3d1666b8dc710af2b216c8ce71ecc2ac471.tar.bz2
plus-8ca1f3d1666b8dc710af2b216c8ce71ecc2ac471.tar.xz
plus-8ca1f3d1666b8dc710af2b216c8ce71ecc2ac471.zip
Move doctest and catch files into unittests directory.
-rw-r--r--src/Makefile.am4
-rw-r--r--src/maingui.cpp4
-rw-r--r--src/unittests/catch.hpp (renamed from src/test/catch.hpp)0
-rw-r--r--src/unittests/doctest.h (renamed from src/test/doctest.h)0
-rw-r--r--src/unittests/unittests.h4
-rwxr-xr-xtools/ci/jobs/clang_tidy.sh4
-rwxr-xr-xtools/ci/jobs/cpplint.sh3
-rwxr-xr-xtools/ci/jobs/nsiqcppstyle.sh1
-rwxr-xr-xtools/ci/scripts/init.sh3
9 files changed, 13 insertions, 10 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index b389ffc8f..14e4b875c 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -2021,11 +2021,11 @@ manaplustests_SOURCES = \
if ENABLE_UNITTESTS_CATCH
manaplustests_SOURCES += \
- test/catch.hpp
+ unittests/catch.hpp
endif
if ENABLE_UNITTESTS_DOCTEST
manaplustests_SOURCES += \
- test/doctest.h
+ unittests/doctest.h
endif
if MINGW
diff --git a/src/maingui.cpp b/src/maingui.cpp
index 235d34df8..9e7efa9c6 100644
--- a/src/maingui.cpp
+++ b/src/maingui.cpp
@@ -56,11 +56,11 @@ PRAGMA48(GCC diagnostic pop)
#include "resources/dye/dyepalette.h"
#ifdef UNITTESTS_CATCH
#define CATCH_CONFIG_RUNNER
-#include "test/catch.hpp"
+#include "unittests/catch.hpp"
#endif // UNITTESTS_CATCH
#ifdef UNITTESTS_DOCTEST
#define DOCTEST_CONFIG_IMPLEMENT
-#include "test/doctest.h"
+#include "unittests/doctest.h"
#endif // UNITTESTS_DOCTEST
#else // UNITTESTS
#include "utils/xml.h"
diff --git a/src/test/catch.hpp b/src/unittests/catch.hpp
index 64d1cafc4..64d1cafc4 100644
--- a/src/test/catch.hpp
+++ b/src/unittests/catch.hpp
diff --git a/src/test/doctest.h b/src/unittests/doctest.h
index 695c271b5..695c271b5 100644
--- a/src/test/doctest.h
+++ b/src/unittests/doctest.h
diff --git a/src/unittests/unittests.h b/src/unittests/unittests.h
index 13be1b9c0..a83a0a198 100644
--- a/src/unittests/unittests.h
+++ b/src/unittests/unittests.h
@@ -24,7 +24,7 @@
#include "localconsts.h"
#ifdef UNITTESTS_CATCH
-#include "test/catch.hpp"
+#include "unittests/catch.hpp"
#endif // UNITTESTS_CATCH
#ifdef UNITTESTS_DOCTEST
@@ -41,7 +41,7 @@
PRAGMA5(GCC diagnostic push)
PRAGMA5(GCC diagnostic ignored "-Wsuggest-override")
-#include "test/doctest.h"
+#include "unittests/doctest.h"
PRAGMA5(GCC diagnostic pop)
#undef TEST_CASE
diff --git a/tools/ci/jobs/clang_tidy.sh b/tools/ci/jobs/clang_tidy.sh
index ba8606641..8bc7786ab 100755
--- a/tools/ci/jobs/clang_tidy.sh
+++ b/tools/ci/jobs/clang_tidy.sh
@@ -18,8 +18,8 @@ check_error $?
cd ..
grep "warning:" logs/clang_tidy.txt \
-| grep -v "/src/test/doctest.h" \
-| grep -v "/src/test/catch.hpp" \
+| grep -v "/src/unittests/doctest.h" \
+| grep -v "/src/unittests/catch.hpp" \
| grep -v "/src/sdl2gfx/" \
| grep -v "/src/debug/" \
>${ERRFILE}
diff --git a/tools/ci/jobs/cpplint.sh b/tools/ci/jobs/cpplint.sh
index e9e286f23..4e9eab3c2 100755
--- a/tools/ci/jobs/cpplint.sh
+++ b/tools/ci/jobs/cpplint.sh
@@ -41,7 +41,8 @@ find src -type f -name "*.cc" -exec $CHECKER {} \; 2>>${ERRFILE}2
grep ": " ${ERRFILE}2 | \
grep -v "src/debug/" | \
-grep -v "test/doctest.h" | \
+grep -v "test/unittests/doctest.h" | \
+grep -v "test/unittests/catch.hpp" | \
grep -v "debug/fast_mutex" | \
grep -v "sdl2gfx/SDL2" \
>${ERRFILE}
diff --git a/tools/ci/jobs/nsiqcppstyle.sh b/tools/ci/jobs/nsiqcppstyle.sh
index 5e2785f54..7721398ec 100755
--- a/tools/ci/jobs/nsiqcppstyle.sh
+++ b/tools/ci/jobs/nsiqcppstyle.sh
@@ -9,6 +9,7 @@ rm -rf nsiqcppstyle.git
./nsiqcppstyle.git/nsiqcppstyle --ci --show-url src \
| grep -v "catch.hpp" \
+| grep -v "doctest.h" \
| grep -v "sdl2gfx" \
| grep -v "/debug/" \
>logs/nsiqcppstyle1.log
diff --git a/tools/ci/scripts/init.sh b/tools/ci/scripts/init.sh
index 0ef5c219e..f435eed99 100755
--- a/tools/ci/scripts/init.sh
+++ b/tools/ci/scripts/init.sh
@@ -280,7 +280,8 @@ function run_mplint {
rm $ERRFILE
echo "mplint/src/mplint $*"
mplint/src/mplint $* \
- | grep -v "src/test/doctest.h" \
+ | grep -v "src/unittests/doctest.h" \
+ | grep -v "src/unittests/catch.hpp" \
| grep -v "src/debug/" \
>$ERRFILE
run_check_warnings