Skip to content

Commit 402f66b

Browse files
committed
t: cover large parallel fsck
Problem: flux-fsck now checks valref blobrefs in parallel but there are no tests to stress this. Add a large 2000 element valref blobref array into the tests in t2816-fsck-cmd.t.
1 parent 285b370 commit 402f66b

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

t/t2816-fsck-cmd.t

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,28 @@ test_expect_success 'flux-fsck verbose works' '
5050
grep "dir\.b" verbose.out &&
5151
grep "alink" verbose.out
5252
'
53+
# Cover value with a very large number of appends
54+
# N.B. from 1000 to 3000 instead of 0 to 2000, easier to debug errors
55+
# using fold(1) (i.e. all numbers same width)
56+
test_expect_success LONGTEST 'load kvs and create some kvs content' '
57+
flux module load kvs &&
58+
for i in `seq 1000 3000`; do
59+
flux kvs put --append bigval=${i}
60+
done &&
61+
flux kvs get bigval > bigval.exp
62+
'
63+
test_expect_success LONGTEST 'call sync to ensure we have checkpointed' '
64+
flux kvs sync
65+
'
66+
test_expect_success LONGTEST 'unload kvs' '
67+
flux module remove kvs
68+
'
69+
test_expect_success LONGTEST 'flux-fsck works' '
70+
flux fsck --verbose 2> bigval.out &&
71+
grep "Checking integrity" bigval.out &&
72+
grep "bigval" bigval.out &&
73+
grep "Total errors: 0" bigval.out
74+
'
5375
test_expect_success 'load kvs' '
5476
flux module load kvs
5577
'

0 commit comments

Comments
 (0)