[LTP] [PATCH 1/1] runltp: fix regex for disabled testcases

Vasileios Almpanis via ltp
2026-02-03T09:43:47Z

Currently for all disabled testcases we append TCONF
so that they don't completely disappear from the results.
Unfortunately this regex also matches comments that
include the testcase name creating multiple results for the
same testcase as with the folloing example.

sed -n '/\<cgroup\>/p' runtest/controllers
cgroup cgroup_regression_test.sh
# Stress test for debug cgroup
# Stress test for cpuset cgroup
# Stress test for cpu cgroup
# Stress test for cpuacct cgroup
# Stress test for memory cgroup
# Stress test for freezer cgroup
# Stress test for devices cgroup
# Stress test for blkio cgroup
# Stress test for net_cls cgroup
# Stress test for perf_event cgroup
# Stress test for net_prio cgroup
# Stress test for hugetlb cgroup

Add a line anchor to the regex to not match
lines not related to the disabled testcases.

Signed-off-by: Vasileios Almpanis <vasileios.almpanis@virtuozzo.com>
---
runltp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/runltp b/runltp
index 0d9062569..e1748e493 100755
--- a/runltp
+++ b/runltp
@@ -650,7 +650,7 @@ EOF
if [ -n "${SKIPFILE}" ]; then
for test_name in $(awk '{print $1}' "${SKIPFILE}"); do
case "${test_name}" in \#*) continue;; esac
- sed -i "/\<${test_name}\>/c\\${test_name} exit 32;" alltests
+ sed -i "/^\<${test_name}\>/c\\${test_name} exit 32;" alltests
done
fi

--
2.43.0