Skip to content

Commit

Permalink
tests/leaks.sh: quadruple maximum number of test iterations
Browse files Browse the repository at this point in the history
There were still intermittent leak test failures on Debian.
They're clearly spurious as a different test fails each time.

My testing on a Debian 11.4.0 VM showed that it takes not a
doubling, but a quadrupling of the maximum number of test
iterations (from 16384==2**14 to 65536==2**16) for that system's
memory state to stabilise enough to avoid spurious test failurese.

Resolves: #501
  • Loading branch information
McDutchie committed Jul 31, 2022
1 parent 38acc02 commit b07d7b2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cmd/ksh93/tests/leaks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ fi
# lucky. If the OS decides to randomly grow the memory heap, it may take more tries, but hopefully not more than
# $max_iter iterations. If the loop counter reaches $max_iter, then we assume a memory leak and throw a test failure.

typeset -ir max_iter=16384 block_iter=128 min_good_blocks=16
typeset -ir max_iter=65536 block_iter=128 min_good_blocks=16

# Set up test block construct.
# Known leaks can be marked known=y to turn them into non-fail warnings.
Expand Down

0 comments on commit b07d7b2

Please sign in to comment.