Make GoogleTest optional on Linux
Closed this issue · 5 comments
Currently the CMake script assumes that the GoogleTest framework is installed, and will fail if not. We should remove this as a dependency and make it optional to run the tests.
hmm. that's unintentional. Did you try with -DMEI_BUILD_TESTS=False ?
No, because that wasn't immediately apparent. After looking a bit further, it looks like this is the problem:
option(MEI_BUILD_TESTS "Build all unit tests" ON)
option(MEI_TEST_COVERAGE "Build with test coverage support" OFF)
Would it be OK to set MEI_BUILD_TESTS to OFF?
I will be making the change to turn this OFF by default, with an optional flag to enable it. Otherwise, gtest becomes a dependency for libMEI on Linux, but not on any other platform.
I think a good compromise is to make it disable tests if gtest isn't found,
but compile them if it is.
On Wed, Dec 14, 2011 at 1:47 PM, Andrew Hankinson <
reply@reply.github.com
wrote:
I will be making the change to turn this OFF by default, with an optional
flag to enable it. Otherwise, gtest becomes a dependency for libMEI on
Linux, but not on any other platform.
Reply to this email directly or view it on GitHub:
#50 (comment)
Sure, I could live with that.
On 2011-12-14, at 1:49 PM, Alastair Porter wrote:
I think a good compromise is to make it disable tests if gtest isn't found,
but compile them if it is.On Wed, Dec 14, 2011 at 1:47 PM, Andrew Hankinson <
reply@reply.github.comwrote:
I will be making the change to turn this OFF by default, with an optional
flag to enable it. Otherwise, gtest becomes a dependency for libMEI on
Linux, but not on any other platform.
Reply to this email directly or view it on GitHub:
#50 (comment)
Reply to this email directly or view it on GitHub:
#50 (comment)