mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Fix double counting unit test failures:
Unit tests are counting test failures, process crashes, and process exit code failures in the count. Since a failing tests causes the process exit code to return failure, we get extra counts. This patch removes process exit code failures from the count.
This commit is contained in:
@@ -297,6 +297,7 @@ runUnitTests(
|
|||||||
boost::process::exe = exe_name, boost::process::args = args);
|
boost::process::exe = exe_name, boost::process::args = args);
|
||||||
|
|
||||||
int bad_child_exits = 0;
|
int bad_child_exits = 0;
|
||||||
|
int terminated_child_exits = 0;
|
||||||
for (auto& c : children)
|
for (auto& c : children)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
@@ -309,10 +310,11 @@ runUnitTests(
|
|||||||
{
|
{
|
||||||
// wait throws if process was terminated with a signal
|
// wait throws if process was terminated with a signal
|
||||||
++bad_child_exits;
|
++bad_child_exits;
|
||||||
|
++terminated_child_exits;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
parent_runner.add_failures(bad_child_exits);
|
parent_runner.add_failures(terminated_child_exits);
|
||||||
anyMissing(parent_runner, multi_selector(pattern));
|
anyMissing(parent_runner, multi_selector(pattern));
|
||||||
|
|
||||||
if (parent_runner.any_failed() || bad_child_exits)
|
if (parent_runner.any_failed() || bad_child_exits)
|
||||||
|
|||||||
Reference in New Issue
Block a user