mirror of
https://github.com/ziglang/zig.git
synced 2026-01-21 06:45:24 +00:00
test: fix io_uring timing test to skip on failure
This commit is contained in:
parent
8ebfdc14f6
commit
cc435dab2f
@ -1353,7 +1353,9 @@ test "timeout (after a relative time)" {
|
||||
.res = -linux.ETIME,
|
||||
.flags = 0,
|
||||
}, cqe);
|
||||
testing.expectApproxEqAbs(@intToFloat(f64, ms), @intToFloat(f64, stopped - started), margin);
|
||||
|
||||
// Tests should not depend on timings: skip test (result) if outside margin.
|
||||
if (!std.math.approxEqAbs(f64, ms, @intToFloat(f64, stopped - started), margin)) return error.SkipZigTest;
|
||||
}
|
||||
|
||||
test "timeout (after a number of completions)" {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user