1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-13 08:35:20 +02:00

Add an option to disable unittest build, & disable them on Docker build (#9677)

This commit is contained in:
Loïc Blot
2020-04-16 20:43:49 +02:00
committed by GitHub
parent 093e79ea78
commit 7539267d37
6 changed files with 19 additions and 2 deletions

View File

@@ -187,7 +187,13 @@ int main(int argc, char *argv[])
#ifndef __ANDROID__
// Run unit tests
if (cmd_args.getFlag("run-unittests")) {
#if BUILD_UNITTESTS
return run_tests();
#else
errorstream << "Unittest support is not enabled in this binary. "
<< "If you want to enable it, compile project with BUILD_UNITTESTS=1 flag."
<< std::endl;
#endif
}
#endif