From 2bb25db66a044f8c489ab6449386a32f31de1256 Mon Sep 17 00:00:00 2001 From: Dimitar Trendafilov Date: Sun, 28 Oct 2018 18:08:12 +0200 Subject: Added googletest based tests --- JSImpl/solution/genie.lua | 2 ++ JSImpl/test/empty.cpp | 5 +++++ JSImpl/test/genie.lua | 51 +++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 58 insertions(+) create mode 100644 JSImpl/test/empty.cpp create mode 100644 JSImpl/test/genie.lua (limited to 'JSImpl') diff --git a/JSImpl/solution/genie.lua b/JSImpl/solution/genie.lua index 571bf9c..5806154 100644 --- a/JSImpl/solution/genie.lua +++ b/JSImpl/solution/genie.lua @@ -23,3 +23,5 @@ solution 'IPL' uuid(os.uuid('JSImpl')) files '../src/*.cpp' files '../src/*.h' + + include '../test' diff --git a/JSImpl/test/empty.cpp b/JSImpl/test/empty.cpp new file mode 100644 index 0000000..53d601d --- /dev/null +++ b/JSImpl/test/empty.cpp @@ -0,0 +1,5 @@ +#include + +TEST(Empty, Empty) +{ +} diff --git a/JSImpl/test/genie.lua b/JSImpl/test/genie.lua new file mode 100644 index 0000000..c46b4a8 --- /dev/null +++ b/JSImpl/test/genie.lua @@ -0,0 +1,51 @@ +project 'Test' + kind 'ConsoleApp' + language 'C++' + uuid(os.uuid('Test')) + + files '*.cpp' + + includedirs { + 'googletest/googletest/include', + 'googletest/googlemock/include', + '../JSImpl/googlemock/include', + } + links { + 'gtest', + 'gmock', + 'gtest_main', + 'pthread', + } + +project 'gtest' + kind 'StaticLib' + language 'C++' + uuid(os.uuid('gtest')) + files 'googletest/googletest/src/gtest-all.cc' + files 'googletest/googletest/include/gtest/*.h' + includedirs { + 'googletest/googletest', + 'googletest/googletest/include', + } + +project 'gmock' + kind 'StaticLib' + language 'C++' + uuid(os.uuid('gmock')) + files 'googletest/googlemock/src/gmock-all.cc' + files 'googletest/googlemock/include/gmock/*.h' + includedirs { + 'googletest/googlemock', + 'googletest/googlemock/include', + 'googletest/googletest/include', + } + +project 'gtest_main' + kind 'StaticLib' + language 'C++' + uuid(os.uuid('gtest_main')) + files 'googletest/googletest/src/gtest_main.cc' + includedirs { + 'googletest/googletest', + 'googletest/googletest/include', + } -- cgit v1.3.1-23-gd82d