Compare commits

..

1 Commits

Author SHA1 Message Date
e0559c2ed1 tests: fill out coverage for new fsck features 2020-08-17 23:26:34 -04:00
8 changed files with 5 additions and 7 deletions

View File

@ -511,20 +511,18 @@ class Fsck(object):
# Verify that all timestamps are in range.
match = (ts < stime) | (ts >= etime)
if match.any():
row = numpy.argmax(match)
row = start + numpy.argmax(match)
raise FsckError("%s: data timestamp %d at row %d "
"outside interval range [%d,%d)",
path, ts[row], row + start,
path, data['timestamp'][row], row,
stime, etime)
# Verify that timestamps are monotonic
match = numpy.diff(ts) <= 0
if match.any():
row = numpy.argmax(match)
raise FsckError("%s: non-monotonic timestamp (%d -> %d)"
" at row %d", path, ts[row], ts[row+1],
row + start)
row = start + numpy.argmax(match)
raise FsckError("%s: non-monotonic timestamp (%d -> %d) "
"at row %d", path, ts[row], ts[row+1], row)
first_ts = ts[0]
if last_ts is not None and first_ts <= last_ts:
raise FsckError("%s: first interval timestamp %d is not "

Binary file not shown.

Binary file not shown.

Binary file not shown.