Skip to content

Commit

Permalink
testsuite: test for shell output truncation in t9000-system.t
Browse files Browse the repository at this point in the history
Problem: There is no test that ensures the job shell truncates output
to 10M by default for guest jobs in a multiuser instance.

Add a test to t9000-system.t that ensures output is truncated in this
case.
  • Loading branch information
grondo committed Feb 12, 2024
1 parent 5f5098e commit 2299dfe
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions t/system/0001-basic.t
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,9 @@ test_expect_success 'flux jobs lists job with correct userid' '
test_expect_success 'flux proxy can submit jobs to system instance' '
flux proxy $(flux getattr local-uri) flux submit true
'
test_expect_success 'flux-shell limits kvs output to 10M for guest jobs' '
dd if=/dev/urandom bs=10240 count=800 | base64 --wrap 79 >trunc.exp &&
flux run cat expected >output 2>trunc.err &&
test_debug "cat trunc.err" &&
grep "stdout.*truncated" trunc.error
'

0 comments on commit 2299dfe

Please sign in to comment.