linuxkit/test/cases/_lib/lib.sh
Avi Deitcher efb139697e
always tee test linuxkit run to tty, so if it gets stuck, we see why (#4107)
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2025-02-19 19:41:06 +02:00

20 lines
592 B
Bash

#!/bin/sh
# Source the main regression test library if present
[ -f "${RT_LIB}" ] && . "${RT_LIB}"
# Temporary directory for tests to use.
LINUXKIT_TMPDIR="${RT_PROJECT_ROOT}/_tmp"
# The top-level group.sh of the project creates a env.sh file
# containing environment variables for tests. Source it if present.
[ -f "${LINUXKIT_TMPDIR}/env.sh" ] && . "${LINUXKIT_TMPDIR}/env.sh"
# FIXME: Should source the rtf/lib/lib.sh instead
RT_CANCEL=253
# command to run `linuxkit run` that includes streaming to stderr, so you never miss logs
linuxkitrun() {
linuxkit run $@ | tee /dev/stderr
}