]> granicus.if.org Git - llvm/commitdiff
[lit] Fix race between shtest-shell and max-failures tests
authorReid Kleckner <rnk@google.com>
Wed, 26 Jul 2017 22:57:32 +0000 (22:57 +0000)
committerReid Kleckner <rnk@google.com>
Wed, 26 Jul 2017 22:57:32 +0000 (22:57 +0000)
Previously these tests would use the same Output directory leading to
flaky non-deterministic failures.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@309227 91177308-0d34-0410-b5e6-96231b3b80d8

utils/lit/tests/Inputs/max-failures/lit.cfg [new file with mode: 0644]
utils/lit/tests/max-failures.py

diff --git a/utils/lit/tests/Inputs/max-failures/lit.cfg b/utils/lit/tests/Inputs/max-failures/lit.cfg
new file mode 100644 (file)
index 0000000..50d0756
--- /dev/null
@@ -0,0 +1,6 @@
+import lit.formats
+config.name = 'shtest-shell'
+config.suffixes = ['.txt']
+config.test_format = lit.formats.ShTest()
+config.test_source_root = os.path.dirname(__file__) + '/../shtest-shell'
+config.test_exec_root = None
index 5cc258dd08aa88f89bc2be7f52e6f74e29ba69dd..bc58e9a4e47f412cf1ba0f794f123943726938a3 100644 (file)
@@ -1,9 +1,9 @@
 # Check the behavior of --max-failures option.
 #
-# RUN: not %{lit} -j 1 -v %{inputs}/shtest-shell > %t.out
-# RUN: not %{lit} --max-failures=1 -j 1 -v %{inputs}/shtest-shell >> %t.out
-# RUN: not %{lit} --max-failures=2 -j 1 -v %{inputs}/shtest-shell >> %t.out
-# RUN: not %{lit} --max-failures=0 -j 1 -v %{inputs}/shtest-shell 2>> %t.out
+# RUN: not %{lit} -j 1 -v %{inputs}/max-failures > %t.out
+# RUN: not %{lit} --max-failures=1 -j 1 -v %{inputs}/max-failures >> %t.out
+# RUN: not %{lit} --max-failures=2 -j 1 -v %{inputs}/max-failures >> %t.out
+# RUN: not %{lit} --max-failures=0 -j 1 -v %{inputs}/max-failures 2>> %t.out
 # RUN: FileCheck < %t.out %s
 #
 # END.