about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
authorDan Liew <daniel.liew@imperial.ac.uk>2014-01-14 18:06:52 +0000
committerDan Liew <daniel.liew@imperial.ac.uk>2014-01-20 14:46:52 +0000
commit54b5b1d8fc99376fccbbcb471825012dfa1e4017 (patch)
tree2d7f3f90ee95893a3839b21a73dad04e1f187f39
parente2f56b6bbb4bee1d1384b2b23930e108449d30b2 (diff)
downloadklee-54b5b1d8fc99376fccbbcb471825012dfa1e4017.tar.gz
Fixed test cases that fail if using an in-source build
-rw-r--r--test/Coverage/ReadArgs.c6
-rw-r--r--test/regression/2007-08-01-bool-zext-in-call.ll11
-rw-r--r--test/regression/2007-10-12-failed-make-symbolic-after-copy.c2
3 files changed, 13 insertions, 6 deletions
diff --git a/test/Coverage/ReadArgs.c b/test/Coverage/ReadArgs.c
index 7ebf056e..ddfb1747 100644
--- a/test/Coverage/ReadArgs.c
+++ b/test/Coverage/ReadArgs.c
@@ -1,8 +1,8 @@
 // RUN: %llvmgcc %s -emit-llvm -O0 -c -o %t1.bc
-// RUN: rm -rf xxx
-// RUN: echo " --output-dir=xxx " > %t1.args
+// RUN: rm -rf %T/xxx
+// RUN: echo " --output-dir=%T/xxx " > %t1.args
 // RUN: %klee --read-args %t1.args %t1.bc
-// RUN: test -d xxx
+// RUN: test -d %T/xxx
 
 int main() {
   return 0;
diff --git a/test/regression/2007-08-01-bool-zext-in-call.ll b/test/regression/2007-08-01-bool-zext-in-call.ll
index d10a41ef..fc77785d 100644
--- a/test/regression/2007-08-01-bool-zext-in-call.ll
+++ b/test/regression/2007-08-01-bool-zext-in-call.ll
@@ -1,5 +1,12 @@
-; RUN: llvm-as -f %s -o - | %klee 2> %t1.log
-; RUN: not test -f klee-last/test0001.abort.err
+; RUN: rm -rf %T/xxx
+;
+; The output directory must be explicitly set so that it ends up in the Output/
+; directory which is not scanned for .ll files by llvm-lit, otherwise running
+; test suite a second time will cause problems because assembly.ll generated by
+; executing this test case the first time will be detected as a test case.
+;
+; RUN: llvm-as -f %s -o - | %klee --output-dir=%T/xxx
+; RUN: not test -f %T/xxx/klee-last/test0001.abort.err
 
 declare void @klee_abort()
 
diff --git a/test/regression/2007-10-12-failed-make-symbolic-after-copy.c b/test/regression/2007-10-12-failed-make-symbolic-after-copy.c
index e9a280c3..bfe61f2c 100644
--- a/test/regression/2007-10-12-failed-make-symbolic-after-copy.c
+++ b/test/regression/2007-10-12-failed-make-symbolic-after-copy.c
@@ -1,6 +1,6 @@
 // RUN: %llvmgcc %s -emit-llvm -O0 -c -o %t1.bc
 // RUN: %klee %t1.bc
-// RUN: test -f klee-last/test000001.ktest
+// RUN: test -f %T/klee-last/test000001.ktest
 
 int main() {
   unsigned x, y[4];