Step: baremetalds-sno-test

The Baremtal DS E2E single-node step executes the common end-to-end test suite.

Container image used for this step: tests

tests resolves to an image built or imported by the ci-operator configuration (documentation).

Environment

Step exposes no environmental variables except the defaults.

Source Code

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!/bin/bash

set -o nounset
set -o errexit
set -o pipefail
set -x

echo "************ baremetalds single-node test command ************"

# Fetch packet basic configuration
# shellcheck source=/dev/null
source "${SHARED_DIR}/packet-conf.sh"

collect_artifacts() {
    echo "### Fetching results"
    ssh "${SSHOPTS[@]}" "root@${IP}" tar -czf - /tmp/artifacts | tar -C "${ARTIFACT_DIR}" -xzf -
}
trap collect_artifacts EXIT TERM

# Copy test binaries on packet server
echo "### Copying test binaries"
scp "${SSHOPTS[@]}" /usr/bin/openshift-tests /usr/bin/kubectl "root@${IP}:/usr/local/bin"

# Tests execution
set +e

if [[ -s "${SHARED_DIR}/test-list" ]]; then
    echo "### Copying test-list file"
    scp \
        "${SSHOPTS[@]}" \
        "${SHARED_DIR}/test-list" \
        "root@${IP}:/tmp/test-list"
    echo "### Running tests"
    timeout \
    --kill-after 10m \
    120m \
    ssh \
        "${SSHOPTS[@]}" \
        "root@${IP}" \
        openshift-tests \
        run \
        "openshift/conformance/parallel" \
        --dry-run \
        \| grep -Ff /tmp/test-list \|openshift-tests run -o /tmp/artifacts/e2e.log --junit-dir /tmp/artifacts/junit -f -
else
    echo "### Running tests"
    ssh \
        "${SSHOPTS[@]}" \
        "root@${IP}" \
        openshift-tests \
        run \
        "openshift/conformance/parallel" \
        --dry-run \
        \| grep 'Feature:ProjectAPI' \| openshift-tests run -o /tmp/artifacts/e2e.log --junit-dir /tmp/artifacts/junit -f -
fi

rv=$?

set -e
echo "### Done! (${rv})"
exit $rv

Properties

Property Value Description
Termination grace period[?] 10m0s Period of time until SIGKILL signal is sent to the test pod (after SIGTERM signal is sent).
Resource requests (cpu) 3 Used in .resources.requests of the pod running this step.
Resource requests (memory) 600Mi Used in .resources.requests of the pod running this step.
Resource limits (memory) 2Gi Used in .resources.limits of the pod running this step.

GitHub Link:

https://github.com/openshift/release/blob/master/ci-operator/step-registry/baremetalds/sno/test/baremetalds-sno-test-ref.yaml

Owners:

Approvers:

Source code for this page located on GitHub