diff --git a/.github/workflows/GnuTests.yml b/.github/workflows/GnuTests.yml index 55c57080821..22077b5ff7f 100644 --- a/.github/workflows/GnuTests.yml +++ b/.github/workflows/GnuTests.yml @@ -1,6 +1,6 @@ name: GnuTests -# spell-checker:ignore (abbrev/names) CodeCov gnulib GnuTests Swatinem +# spell-checker:ignore (abbrev/names) CodeCov gnulib GnuTests Swatinem tmpfs # spell-checker:ignore (jargon) submodules devel # spell-checker:ignore (libs/utils) autopoint chksum getenforce gperf lcov libexpect limactl pyinotify setenforce shopt texinfo valgrind libattr libcap taiki-e # spell-checker:ignore (options) Ccodegen Coverflow Cpanic Zpanic @@ -115,6 +115,16 @@ jobs: cd 'uutils' env PROFILE=release-small bash util/build-gnu.sh + ### Test environment setup + - name: Setup specific GNU tests environment + shell: bash + run: | + # for tac/tac-continue test + export FULL_PARTITION_TMPDIR=/mnt/full_partition + sudo mount --mkdir=0777 --types tmpfs --options size=1M tmpfs $FULL_PARTITION_TMPDIR + dd if=/dev/zero of=$FULL_PARTITION_TMPDIR/data bs=1M count=1 + echo "FULL_PARTITION_TMPDIR=$FULL_PARTITION_TMPDIR" >> $GITHUB_ENV + ### Run tests as user - name: Run GNU tests shell: bash diff --git a/util/gnu-patches/series b/util/gnu-patches/series index 5fb1398cd17..f04bf77f1ab 100644 --- a/util/gnu-patches/series +++ b/util/gnu-patches/series @@ -10,4 +10,5 @@ tests_sort_merge.pl.patch tests_tsort.patch tests_du_move_dir_while_traversing.patch test_mkdir_restorecon.patch +tests_tac_continue.patch error_msg_uniq.diff diff --git a/util/gnu-patches/tests_tac_continue.patch b/util/gnu-patches/tests_tac_continue.patch new file mode 100644 index 00000000000..d530ed58268 --- /dev/null +++ b/util/gnu-patches/tests_tac_continue.patch @@ -0,0 +1,24 @@ +Index: gnu/tests/tac/tac-continue.sh +=================================================================== +--- gnu.orig/tests/tac/tac-continue.sh ++++ gnu/tests/tac/tac-continue.sh +@@ -59,11 +59,17 @@ seq 5 > in + + # Give tac a fifo command line argument. + # This makes it try to create a temporary file in $TMPDIR. ++ ++# uutils does not create this temporary file in $TMPDIR, so the expected result is different ++# there is just no difference from normal operation ++# that means tac returns with success and the expected output the reverse of inputs ++ + mkfifo_or_skip_ fifo + seq 1000 > fifo & pid=$! +-TMPDIR=$FULL_PARTITION_TMPDIR tac fifo in >out 2>err && fail=1 ++TMPDIR=$FULL_PARTITION_TMPDIR tac fifo in >out 2>err || fail=1 + +-cat <<\EOF > exp || framework_failure_ ++seq 1000 -1 1 > exp || framework_failure_ ++cat <<\EOF >> exp || framework_failure_ + 5 + 4 + 3 diff --git a/util/why-skip.md b/util/why-skip.md index f179a58bb1c..647bc06dbf4 100644 --- a/util/why-skip.md +++ b/util/why-skip.md @@ -35,9 +35,6 @@ = timeout returned 142. SIGALRM not handled? = * tests/misc/timeout-group.sh -= FULL_PARTITION_TMPDIR not defined = -* tests/misc/tac-continue.sh - = can't get window size = * tests/misc/stty-row-col.sh