34 lines
1.4 KiB
Bash
Executable File
34 lines
1.4 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
# This is the expected entry point for Cockpit CI; will be called without
|
|
# arguments but with an appropriate $TEST_OS, and optionally $TEST_SCENARIO
|
|
|
|
set -eu
|
|
|
|
test/common/make-bots
|
|
test/common/pixel-tests pull
|
|
|
|
TEST_SCENARIO="${TEST_SCENARIO:-verify}"
|
|
[ "${TEST_SCENARIO}" = "${TEST_SCENARIO%%devel}" ] || export NODE_ENV=development
|
|
|
|
case "$TEST_SCENARIO" in
|
|
verify|devel|firefox|firefox-devel|pybridge)
|
|
RUN_OPTS="--track-naughties"
|
|
PREPARE_OPTS=""
|
|
[ "${TEST_SCENARIO}" = "${TEST_SCENARIO%%devel}" ] || RUN_OPTS="$RUN_OPTS --coverage"
|
|
[ "${TEST_SCENARIO}" = "${TEST_SCENARIO%%pybridge}" ] || PREPARE_OPTS="$PREPARE_OPTS --python"
|
|
[ "${TEST_SCENARIO}" = "${TEST_SCENARIO##firefox}" ] || export TEST_BROWSER=firefox
|
|
|
|
test/image-prepare --verbose ${PREPARE_OPTS} "${TEST_OS}"
|
|
test/common/run-tests --jobs ${TEST_JOBS:-1} --test-dir test/verify ${RUN_OPTS}
|
|
;;
|
|
daily)
|
|
bots/image-customize --fresh -v --run-command 'dnf -y copr enable rpmsoftwaremanagement/dnf-nightly && dnf -y copr enable @storage/udisks-daily && dnf -y --setopt=install_weak_deps=False update >&2' $TEST_OS
|
|
test/image-prepare --verbose --overlay $TEST_OS
|
|
test/common/run-tests --jobs ${TEST_JOBS:-1} --test-dir test/verify --track-naughties
|
|
;;
|
|
*)
|
|
echo "Unknown test scenario: $TEST_SCENARIO"
|
|
exit 1
|
|
esac
|