small code simplification in stack-test