mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-02 16:38:41 +00:00
Don't silence errorstream in tests (#15629)
This commit is contained in:
parent
eb512cc36a
commit
81f51492ff
1 changed files with 2 additions and 8 deletions
|
@ -212,8 +212,6 @@ bool run_tests()
|
||||||
u64 t1 = porting::getTimeMs();
|
u64 t1 = porting::getTimeMs();
|
||||||
TestGameDef gamedef;
|
TestGameDef gamedef;
|
||||||
|
|
||||||
g_logger.setLevelSilenced(LL_ERROR, true);
|
|
||||||
|
|
||||||
u32 num_modules_failed = 0;
|
u32 num_modules_failed = 0;
|
||||||
u32 num_total_tests_failed = 0;
|
u32 num_total_tests_failed = 0;
|
||||||
u32 num_total_tests_run = 0;
|
u32 num_total_tests_run = 0;
|
||||||
|
@ -243,11 +241,9 @@ bool run_tests()
|
||||||
|
|
||||||
u64 tdiff = porting::getTimeMs() - t1;
|
u64 tdiff = porting::getTimeMs() - t1;
|
||||||
|
|
||||||
g_logger.setLevelSilenced(LL_ERROR, false);
|
|
||||||
|
|
||||||
const char *overall_status = (num_modules_failed == 0) ? "PASSED" : "FAILED";
|
const char *overall_status = (num_modules_failed == 0) ? "PASSED" : "FAILED";
|
||||||
|
|
||||||
rawstream
|
rawstream << "\n"
|
||||||
<< "++++++++++++++++++++++++++++++++++++++++"
|
<< "++++++++++++++++++++++++++++++++++++++++"
|
||||||
<< "++++++++++++++++++++++++++++++++++++++++" << std::endl
|
<< "++++++++++++++++++++++++++++++++++++++++" << std::endl
|
||||||
<< "Unit Test Results: " << overall_status << std::endl
|
<< "Unit Test Results: " << overall_status << std::endl
|
||||||
|
@ -283,17 +279,15 @@ bool run_tests(const std::string &module_name)
|
||||||
return catch_test_failures == 0;
|
return catch_test_failures == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
g_logger.setLevelSilenced(LL_ERROR, true);
|
|
||||||
u64 t1 = porting::getTimeMs();
|
u64 t1 = porting::getTimeMs();
|
||||||
|
|
||||||
bool ok = testmod->testModule(&gamedef);
|
bool ok = testmod->testModule(&gamedef);
|
||||||
|
|
||||||
u64 tdiff = porting::getTimeMs() - t1;
|
u64 tdiff = porting::getTimeMs() - t1;
|
||||||
g_logger.setLevelSilenced(LL_ERROR, false);
|
|
||||||
|
|
||||||
const char *overall_status = ok ? "PASSED" : "FAILED";
|
const char *overall_status = ok ? "PASSED" : "FAILED";
|
||||||
|
|
||||||
rawstream
|
rawstream << "\n"
|
||||||
<< "++++++++++++++++++++++++++++++++++++++++"
|
<< "++++++++++++++++++++++++++++++++++++++++"
|
||||||
<< "++++++++++++++++++++++++++++++++++++++++" << std::endl
|
<< "++++++++++++++++++++++++++++++++++++++++" << std::endl
|
||||||
<< "Unit Test Results: " << overall_status << std::endl
|
<< "Unit Test Results: " << overall_status << std::endl
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue