mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2026-11-25 13:11:36 +00:00
test: use comparison assertions that print both values
- EXPECT_EQ/EXPECT_NE instead of EXPECT_TRUE(a == b) in the parts, memory resource and plugin manager tests; split the && checks - ASSERT_NE on the message pointer before it is dereferenced - ASSERT_TRUE/ASSERT_FALSE instead of ASSERT_EQ(x, true/false) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -55,7 +55,7 @@ TEST(PluginManager, LoadPluginDynamic)
|
||||
const auto expected = vector<string>{"test_dummy", "test_dummy2"};
|
||||
auto actual = vector<string>();
|
||||
mgr.ForEachPlugin([&](Plugin& plugin){ actual.push_back(plugin.GetName()); });
|
||||
ASSERT_TRUE(actual == expected);
|
||||
ASSERT_EQ(actual, expected);
|
||||
|
||||
// program options
|
||||
auto count = 0;
|
||||
@@ -88,7 +88,7 @@ TEST(PluginManager, LoadPluginStatic)
|
||||
const auto expected = vector<string>{"control"};
|
||||
auto actual = vector<string>();
|
||||
mgr.ForEachPlugin([&](Plugin& plugin){ actual.push_back(plugin.GetName()); });
|
||||
ASSERT_TRUE(actual == expected);
|
||||
ASSERT_EQ(actual, expected);
|
||||
|
||||
// program options
|
||||
auto count = 0;
|
||||
@@ -110,7 +110,7 @@ TEST(PluginManager, Factory)
|
||||
const auto path4 = path{"/lib"};
|
||||
const auto expected = vector<path>{path1, path2, path3, path4};
|
||||
// ASSERT_TRUE(static_cast<bool>(mgr));
|
||||
ASSERT_TRUE(mgr.SearchPaths() == expected);
|
||||
ASSERT_EQ(mgr.SearchPaths(), expected);
|
||||
}
|
||||
|
||||
TEST(PluginManager, SearchPathValidation)
|
||||
|
||||
Reference in New Issue
Block a user