MCPcopy Create free account
hub / github.com/apache/arrow / AssertFingerprintablesNotEqual

Function AssertFingerprintablesNotEqual

cpp/src/arrow/testing/gtest_util.cc:278–297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

276
277template <typename T>
278void AssertFingerprintablesNotEqual(const T& left, const T& right, bool check_metadata,
279 const char* types_plural) {
280 ASSERT_FALSE(left.Equals(right, check_metadata))
281 << types_plural << " '" << left.ToString(check_metadata) << "' and '"
282 << right.ToString(check_metadata) << "' should have compared unequal";
283 auto lfp = left.fingerprint();
284 auto rfp = right.fingerprint();
285 // Note: all types tested in this file should implement fingerprinting,
286 // except extension types.
287 if (lfp != "" && rfp != "") {
288 if (check_metadata) {
289 lfp += left.metadata_fingerprint();
290 rfp += right.metadata_fingerprint();
291 }
292 ASSERT_NE(lfp, rfp) << "Fingerprints for " << types_plural << " '"
293 << left.ToString(check_metadata) << "' and '"
294 << right.ToString(check_metadata)
295 << "' should have compared unequal";
296 }
297}
298
299template <typename T>
300void AssertFingerprintablesNotEqual(const std::shared_ptr<T>& left,

Callers

nothing calls this directly

Calls 2

EqualsMethod · 0.45
ToStringMethod · 0.45

Tested by

no test coverage detected