diff --git a/cgroups/automated/run-test.sh b/cgroups/automated/run-test.sh index de5a91366922160c9fcf6626301ec5d623df4344..d5d8796f4771808da545117b1183c6ad66c3a366 100755 --- a/cgroups/automated/run-test.sh +++ b/cgroups/automated/run-test.sh @@ -468,6 +468,23 @@ test_network_cgroup_priority_classification() { trap "_run_cmd _kill_procs; test_failure" ERR trap "_run_cmd _kill_procs" EXIT +if [ -n "$1" ]; then + e=0 + $1 || e=$? + case "$e" in + (0) + echo "$1 passed (exit $e)" + ;; + (77) + echo "$1 skipped (exit $e)" + ;; + (*) + echo "$1 failed (exit $e)" + ;; + esac + exit $e +fi + src_test_pass <<-EOF test_cpu_shares test_memory_limits diff --git a/common/cgroups-resource-control.yaml b/common/cgroups-resource-control.yaml index 4ee9ab6ea97f871b144c1a4c684c0f6c563f7b9c..0d51ecf7ccc24142b01c263a8f85f4886626f415 100644 --- a/common/cgroups-resource-control.yaml +++ b/common/cgroups-resource-control.yaml @@ -21,7 +21,12 @@ install: run: steps: - - common/run-test-in-systemd --name=cgroups-resource-control --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh + - common/run-test-in-systemd --name=cpu-shares --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh test_cpu_shares + - common/run-test-in-systemd --name=memory-limits --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh test_memory_limits + - common/run-test-in-systemd --name=memory-threshold-notification --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh test_memory_threshold_notification + - common/run-test-in-systemd --name=blkio-weights-random-read --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh test_blkio_weights_random_read + - common/run-test-in-systemd --name=blkio-weights-seq-read --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh test_blkio_weights_sequential_read + - common/run-test-in-systemd --name=network-cgroup-prio-class --timeout=900 env DEBUG=2 cgroups/automated/run-test.sh test_network_cgroup_priority_classification parse: pattern: ^(?P<test_case_id>[a-zA-Z0-9_\-\./]+):\s*(?P<result>pass|fail|skip|unknown)$