Skip to content

Commit b1bdece

Browse files
grondomergify[bot]
authored andcommitted
testsuite: fix resource norestrict test
Problem; The resource 'norestrict' test in t2315-resource-system.t uses the output of hwloc-calc, but in some versions of hwloc, that command logs extra lines of data to stdout. Pass the output of `hwloc-calc` to `tail -n1` to avoid spurious test failures on hwloc versions with this misfeature.
1 parent dc3cea7 commit b1bdece

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/t2315-resource-system.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ test_expect_success HAVE_JQ,MULTICORE 'resource norestrict option works' '
136136
hwloc-bind core:0 flux start -s1 \
137137
-o,--config-path=$(pwd)/${name},-Slog-filename=${name}/logfile \
138138
flux mini run -N1 --exclusive \
139-
sh -c "hwloc-bind --get | hwloc-calc --number-of core" \
139+
sh -c "hwloc-bind --get | hwloc-calc --number-of core | tail -n1" \
140140
>${name}/ncores &&
141141
test_debug "cat ${name}/ncores" &&
142142
test $(cat ${name}/ncores) = $NCORES

0 commit comments

Comments
 (0)