Do not enter the test/ directories if AKONADI_BUILD_TESTS is off.
Review Request #119776 - Created Aug. 13, 2014 and submitted
|Raphael Kubo da Costa|
enable_testing() only determines whether a "test" target and the related CTest files will be created. And in Akonadi's case it is actually invoked regardless of the value of the AKONADI_BUILD_TESTS option because Akonadi includes the CTest module, which calls enable_testing() based on the value of another variable, BUILD_TESTING. In any case, whether the executables and libraries that compose Akonadi's unit tests will be built has nothing to do with enable_testing(). To make AKONADI_BUILD_TESTS really disable the build of the unit tests we now avoid entering the tests/ directories at all when it is off, so that neither tests nor targets they depend on get built.
The unit tests are really not built and do not show up in make test.