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:
Claude
2026-11-03 14:43:51 +00:00
committed by Dennis Klein
parent 8ff2214f9c
commit f1ae05b45c
7 changed files with 58 additions and 53 deletions

View File

@@ -212,7 +212,7 @@ void RegionEventSubscriptions(const string& transport, bool external)
}
ASSERT_EQ(region2->GetSize(), r2Size);
ASSERT_EQ(factory->SubscribedToRegionEvents(), false);
ASSERT_FALSE(factory->SubscribedToRegionEvents());
factory->SubscribeToRegionEvents([&, id1, id2, ptr1, ptr2](RegionInfo info) {
LOG(info) << ">>> " << info.event << ": "
<< (info.managed ? "managed" : "unmanaged")
@@ -241,7 +241,7 @@ void RegionEventSubscriptions(const string& transport, bool external)
}
}
});
ASSERT_EQ(factory->SubscribedToRegionEvents(), true);
ASSERT_TRUE(factory->SubscribedToRegionEvents());
LOG(info) << "waiting for blockers...";
ASSERT_TRUE(blocker.Wait());
@@ -259,7 +259,7 @@ void RegionEventSubscriptions(const string& transport, bool external)
LOG(info) << "All done.";
factory->UnsubscribeFromRegionEvents();
ASSERT_EQ(factory->SubscribedToRegionEvents(), false);
ASSERT_FALSE(factory->SubscribedToRegionEvents());
}
void RegionCallbacks(const string& transport, const string& name)