mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-27 19:17:43 +00:00
fix/CICD ~ (GnuTests) polish and revise factor test mutator
This commit is contained in:
parent
5a49813e07
commit
a46521bb8f
1 changed files with 24 additions and 4 deletions
|
@ -70,17 +70,37 @@ sed -i 's|^"\$@|/usr/bin/timeout 600 "\$@|' build-aux/test-driver
|
||||||
sed -i "s/^[[:blank:]]*PATH=.*/ PATH='${UU_BUILD_DIR//\//\\/}\$(PATH_SEPARATOR)'\"\$\$PATH\" \\\/" Makefile
|
sed -i "s/^[[:blank:]]*PATH=.*/ PATH='${UU_BUILD_DIR//\//\\/}\$(PATH_SEPARATOR)'\"\$\$PATH\" \\\/" Makefile
|
||||||
sed -i 's| tr | /usr/bin/tr |' tests/init.sh
|
sed -i 's| tr | /usr/bin/tr |' tests/init.sh
|
||||||
make -j "$(nproc)"
|
make -j "$(nproc)"
|
||||||
if test ${UU_MAKE_PROFILE} != "debug"; then
|
# Handle generated factor tests
|
||||||
|
t_first=00
|
||||||
|
t_max=36
|
||||||
|
t_max_release=20
|
||||||
|
if test "${UU_MAKE_PROFILE}" != "debug"; then
|
||||||
# Generate the factor tests, so they can be fixed
|
# Generate the factor tests, so they can be fixed
|
||||||
# * reduced to 20 to decrease log size (down from 36 expected by GNU)
|
# * reduced to 20 to decrease log size (down from 36 expected by GNU)
|
||||||
# * only for 'release', skipped for 'debug' as redundant and too time consuming (causing timeout errors)
|
# * only for 'release', skipped for 'debug' as redundant and too time consuming (causing timeout errors)
|
||||||
for i in $(seq -w 0 20); do
|
seq=$(
|
||||||
|
i=${t_first}
|
||||||
|
while test "${i}" -le "${t_max_release}"; do
|
||||||
|
printf '%02d ' $i
|
||||||
|
i=$((i + 1))
|
||||||
|
done
|
||||||
|
)
|
||||||
|
for i in ${seq}; do
|
||||||
make "tests/factor/t${i}.sh"
|
make "tests/factor/t${i}.sh"
|
||||||
done
|
done
|
||||||
sed -i -e 's|sha1sum |/usr/bin/sha1sum |' tests/factor/t*sh
|
cat
|
||||||
|
sed -i -e 's|^seq |/usr/bin/seq |' -e 's|sha1sum |/usr/bin/sha1sum |' tests/factor/t*.sh
|
||||||
|
t_first=$((t_max_release + 1))
|
||||||
fi
|
fi
|
||||||
# strip all (debug) or just the longer (release) factor tests from Makefile
|
# strip all (debug) or just the longer (release) factor tests from Makefile
|
||||||
for i in $(seq 20 36); do
|
seq=$(
|
||||||
|
i=${t_first}
|
||||||
|
while test "${i}" -le "${t_max}"; do
|
||||||
|
printf '%02d ' ${i}
|
||||||
|
i=$((i + 1))
|
||||||
|
done
|
||||||
|
)
|
||||||
|
for i in ${seq}; do
|
||||||
echo "strip t${i}.sh from Makefile"
|
echo "strip t${i}.sh from Makefile"
|
||||||
sed -i -e "s/\$(tf)\/t${i}.sh//g" Makefile
|
sed -i -e "s/\$(tf)\/t${i}.sh//g" Makefile
|
||||||
done
|
done
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue