1
0
mirror of https://github.com/facebookincubator/mvfst.git synced 2025-08-06 22:22:38 +03:00

Fix byte event tests on Mac

Summary:
Comparator in test byte event callback class wasn't accounting for the
type field.

Reviewed By: mjoras, lnicco

Differential Revision: D32226068

fbshipit-source-id: 62c67b08f91ff3eee4096fa9dc777fc7000a5854
This commit is contained in:
Konstantin Tsoy
2021-11-05 20:17:46 -07:00
committed by Facebook GitHub Bot
parent 7073261f0d
commit e79bf1a1f9

View File

@@ -167,7 +167,9 @@ class TestByteEventCallback : public QuicSocket::ByteEventCallback {
return folly::hash::hash_combine(e.id, e.offset, e.type);
};
ComparatorFn comparator = [](const ByteEvent& lhs, const ByteEvent& rhs) {
return ((lhs.id == rhs.id) && (lhs.offset == rhs.offset));
return (
(lhs.id == rhs.id) && (lhs.offset == rhs.offset) &&
(lhs.type == rhs.type));
};
std::unordered_map<ByteEvent, Status, HashFn, ComparatorFn> byteEventTracker_{
/* bucket count */ 4,