mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-06-27 06:00:34 +08:00
Tests: reduced timestamp comparison precision to reduce test failure probability with parallel build
This commit is contained in:
@@ -88,7 +88,7 @@ inline uavcan::UtcTime tsUtc(uint64_t usec) { return uavcan::UtcTime::fromUSec(u
|
||||
inline uavcan::MonotonicDuration durMono(int64_t usec) { return uavcan::MonotonicDuration::fromUSec(usec); }
|
||||
|
||||
template <typename T>
|
||||
static bool areTimestampsClose(const T& a, const T& b, int64_t precision_usec = 10000)
|
||||
static bool areTimestampsClose(const T& a, const T& b, int64_t precision_usec = 100000)
|
||||
{
|
||||
return (a - b).getAbs().toUSec() < precision_usec;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user