[NFCI][lit] Unbreak more lit self-tests after D98179
authorRoman Lebedev <lebedev.ri@gmail.com>
Mon, 22 Mar 2021 11:44:30 +0000 (14:44 +0300)
committerRoman Lebedev <lebedev.ri@gmail.com>
Mon, 22 Mar 2021 12:25:32 +0000 (15:25 +0300)
All of these depend on the order of tests, so if one runs them twice,
the tests within them will naturally be reordered
using the previous run times, which breaks them.

llvm/utils/lit/tests/custom-result-category.py
llvm/utils/lit/tests/googletest-format.py
llvm/utils/lit/tests/googletest-upstream-format.py
llvm/utils/lit/tests/progress-bar.py
llvm/utils/lit/tests/reorder.py
llvm/utils/lit/tests/shtest-env.py
llvm/utils/lit/tests/shtest-format.py
llvm/utils/lit/tests/shtest-not.py
llvm/utils/lit/tests/shtest-run-at-line.py
llvm/utils/lit/tests/shtest-shell.py

index 8a374e3..d4608b3 100644 (file)
@@ -1,6 +1,9 @@
 # UNSUPPORTED: system-windows
 # Test lit.main.add_result_category() extension API.
 
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/custom-result-category/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 %{inputs}/custom-result-category | FileCheck %s
 
 # CHECK: CUSTOM_PASS: custom-result-category :: test1.txt
index 8ea2f83..09aa9de 100644 (file)
@@ -1,5 +1,8 @@
 # Check the various features of the GoogleTest format.
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/googletest-format/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -v %{inputs}/googletest-format > %t.out
 # FIXME: Temporarily dump test output so we can debug failing tests on
 # buildbots.
index a620877..517da4a 100644 (file)
@@ -1,5 +1,8 @@
 # Check the various features of the GoogleTest format.
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/googletest-upstream-format/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -v %{inputs}/googletest-upstream-format > %t.out
 # RUN: FileCheck < %t.out %s
 #
index ceeca68..e6dafff 100644 (file)
@@ -1,5 +1,8 @@
 # Check the simple progress bar.
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/progress-bar/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -s %{inputs}/progress-bar > %t.out
 # RUN: FileCheck < %t.out %s
 #
index 7c9dc8d..8e5ecda 100644 (file)
@@ -3,6 +3,7 @@
 # RUN: cp %{inputs}/reorder/.lit_test_times.txt %{inputs}/reorder/.lit_test_times.txt.orig
 # RUN: %{lit} -j1 %{inputs}/reorder | FileCheck %s
 # RUN: not diff %{inputs}/reorder/.lit_test_times.txt %{inputs}/reorder/.lit_test_times.txt.orig
+# RUN: cp %{inputs}/reorder/.lit_test_times.txt.orig %{inputs}/reorder/.lit_test_times.txt
 # END.
 
 # CHECK:     -- Testing: 3 tests, 1 workers --
index a4ddc0c..ead217a 100644 (file)
@@ -1,5 +1,8 @@
 # Check the env command
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/shtest-env/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -a -v %{inputs}/shtest-env \
 # RUN: | FileCheck -match-full-lines %s
 #
index 5c48397..a15c0f9 100644 (file)
@@ -1,5 +1,8 @@
 # Check the various features of the ShTest format.
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/shtest-format/.lit_test_times.txt
+
 # RUN: rm -f %t.xml
 # RUN: not %{lit} -j 1 -v %{inputs}/shtest-format --xunit-xml-output %t.xml > %t.out
 # RUN: FileCheck < %t.out %s
index d361ae8..a391e7e 100644 (file)
@@ -1,5 +1,8 @@
 # Check the not command
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/shtest-not/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -a -v %{inputs}/shtest-not \
 # RUN: | FileCheck -match-full-lines %s
 #
index cd0e081..bf47e64 100644 (file)
@@ -1,6 +1,9 @@
 # Check that -vv makes the line number of the failing RUN command clear.
 # (-v is actually sufficient in the case of the internal shell.)
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/shtest-run-at-line/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -vv %{inputs}/shtest-run-at-line > %t.out
 # RUN: FileCheck --input-file %t.out %s
 #
index 3f1ead3..13cf05f 100644 (file)
@@ -1,5 +1,8 @@
 # Check the internal shell handling component of the ShTest format.
-#
+
+# FIXME: this test depends on order of tests
+# RUN: rm -f %{inputs}/shtest-shell/.lit_test_times.txt
+
 # RUN: not %{lit} -j 1 -v %{inputs}/shtest-shell > %t.out
 # FIXME: Temporarily dump test output so we can debug failing tests on
 # buildbots.
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-0.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-0.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: Only in {{.*}}dir1: dir1unique
 # CHECK: Only in {{.*}}dir2: dir2unique
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-1.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-1.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: *** {{.*}}dir1{{.*}}subdir{{.*}}f01
 # CHECK: --- {{.*}}dir2{{.*}}subdir{{.*}}f01
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-2.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-2.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: Only in {{.*}}dir2: extrafile
 # CHECK: error: command failed with exit status: 1
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-3.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-3.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: Only in {{.*}}dir1: extra_subdir
 # CHECK: error: command failed with exit status: 1
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-4.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-4.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: File {{.*}}dir1{{.*}}extra_subdir is a directory while file {{.*}}dir2{{.*}}extra_subdir is a regular file
 # CHECK: error: command failed with exit status: 1
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-5.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-5.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: Only in {{.*}}dir1: extra_subdir
 # CHECK: error: command failed with exit status: 1
 
 # CHECK: FAIL: shtest-shell :: diff-r-error-6.txt
 # CHECK: *** TEST 'shtest-shell :: diff-r-error-6.txt' FAILED ***
-# CHECK: $ "diff" "-r" 
+# CHECK: $ "diff" "-r"
 # CHECK: # command output:
 # CHECK: File {{.*}}dir1{{.*}}extra_file is a regular empty file while file {{.*}}dir2{{.*}}extra_file is a directory
 # CHECK: error: command failed with exit status: 1