timeout.sh test is busted #355

Closed
opened 2024-05-26 15:09:31 +00:00 by pennae · 1 comment
Owner

apparently something was refactored once and broke the functional-timeout test in ways that did not make the test fail because bash is a horrid testing framework:

if echo "$messages" | grepQuietInvert "timed out"; then
    echo "error: build may have failed for reasons other than timeout; output:"
    echo "$messages" >&2
    exit 1
fi

succeeds even when it's supposed to fail because

error: building of '\''/tmp/nix-shell.WepHjG/nix-test/timeout/store/qssnbllilkb5ijivmz13s96jvjd775ch-timeout.drv^out'\'' from .drv file timed out after 2 seconds'
+(timeout.sh:15) grepQuietInvert 'timed out'
timeout.sh: line 15: grepQuietInvert: command not found
apparently something was refactored once and broke the `functional-timeout` test in ways that did not make the test fail because bash is a horrid testing framework: ``` if echo "$messages" | grepQuietInvert "timed out"; then echo "error: build may have failed for reasons other than timeout; output:" echo "$messages" >&2 exit 1 fi ``` succeeds even when it's supposed to fail because ``` error: building of '\''/tmp/nix-shell.WepHjG/nix-test/timeout/store/qssnbllilkb5ijivmz13s96jvjd775ch-timeout.drv^out'\'' from .drv file timed out after 2 seconds' +(timeout.sh:15) grepQuietInvert 'timed out' timeout.sh: line 15: grepQuietInvert: command not found ```
pennae added the
bug
E/easy
E/help wanted
labels 2024-05-26 15:09:31 +00:00
jade added the
testing
label 2024-05-27 17:32:20 +00:00
Author
Owner

cl/1222 will fix this once marsam submits it :)

cl/1222 will fix this once marsam submits it :)
jade closed this issue 2024-05-30 03:37:05 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: lix-project/lix#355
No description provided.