Skip to content

Commit

Permalink
Add QMCPACK prefix to ERROR and WARNING
Browse files Browse the repository at this point in the history
  • Loading branch information
ye-luo committed Sep 27, 2024
1 parent 0757361 commit 9786c98
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions CMake/macros.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ function(
set_tests_properties(
${TESTNAME}
PROPERTIES FAIL_REGULAR_EXPRESSION
"ERROR"
"QMCPACK ERROR"
PASS_REGULAR_EXPRESSION
"QMCPACK execution completed successfully"
PROCESSORS
Expand All @@ -166,7 +166,7 @@ function(
set_tests_properties(
${TESTNAME}
PROPERTIES FAIL_REGULAR_EXPRESSION
"ERROR"
"QMCPACK ERROR"
PASS_REGULAR_EXPRESSION
"QMCPACK execution completed successfully"
PROCESSORS
Expand Down
4 changes: 2 additions & 2 deletions src/Platforms/Host/OutputManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,9 @@ inline std::ostream& app_summary() { return infoSummary.getStream(); }

inline std::ostream& app_log() { return infoLog.getStream(); }

inline std::ostream& app_error() { return infoError.getStream() << "ERROR "; }
inline std::ostream& app_error() { return infoError.getStream() << "QMCPACK ERROR "; }

inline std::ostream& app_warning() { return infoLog.getStream() << "WARNING "; }
inline std::ostream& app_warning() { return infoLog.getStream() << "QMCPACK WARNING "; }

inline std::ostream& app_debug_stream() { return infoDebug.getStream(); }

Expand Down
6 changes: 3 additions & 3 deletions src/Utilities/tests/test_output_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ TEST_CASE("OutputManager output", "[utilities]")
REQUIRE(summary_out.str() == "test1");
REQUIRE(app_out.str() == "");
REQUIRE(debug_out.str() == "");
REQUIRE(err_out.str() == "ERROR test4");
REQUIRE(err_out.str() == "QMCPACK ERROR test4");

reset_string_output();

Expand All @@ -88,7 +88,7 @@ TEST_CASE("OutputManager output", "[utilities]")
REQUIRE(summary_out.str() == "test5");
REQUIRE(app_out.str() == "test6");
REQUIRE(debug_out.str() == "");
REQUIRE(err_out.str() == "ERROR test8");
REQUIRE(err_out.str() == "QMCPACK ERROR test8");

reset_string_output();

Expand All @@ -102,7 +102,7 @@ TEST_CASE("OutputManager output", "[utilities]")
REQUIRE(summary_out.str() == "test9");
REQUIRE(app_out.str() == "testA");
REQUIRE(debug_out.str() == "testB");
REQUIRE(err_out.str() == "ERROR testC");
REQUIRE(err_out.str() == "QMCPACK ERROR testC");
}

TEST_CASE("OutputManager pause", "[utilities]")
Expand Down

0 comments on commit 9786c98

Please sign in to comment.