[PATCH] D29532: [libFuzzer] Simplify test to work on windows.

Marcos Pividori via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 3 22:29:33 PST 2017

mpividori created this revision.

Environment variables are handled differently on Windows.
In this case it  is not necessary to use environment variables. So, I simplify the test to work on Windows.



Index: lib/Fuzzer/test/dump_coverage.test
--- lib/Fuzzer/test/dump_coverage.test
+++ lib/Fuzzer/test/dump_coverage.test
@@ -1,11 +1,8 @@
-RUN: DIR=%t_workdir
-RUN: BUILD_DIR=$(pwd)
-RUN: rm -rf $DIR && mkdir -p $DIR && cd $DIR
-RUN: not $BUILD_DIR/LLVMFuzzer-NullDerefTest -dump_coverage=1 2>&1 | FileCheck %s
-RUN: ls *.sancov | xargs sancov -covered-functions $BUILD_DIR/LLVMFuzzer-NullDerefTest* | FileCheck %s --check-prefix=SANCOV
-RUN: $BUILD_DIR/LLVMFuzzer-DSOTest -dump_coverage=1 -runs=0 2>&1 | FileCheck %s --check-prefix=DSO
-RUN: not $BUILD_DIR/LLVMFuzzer-NullDerefTest -dump_coverage=0 2>&1 | FileCheck %s --check-prefix=NOCOV
-RUN: rm -rf $DIR
+RUN: rm -f *.sancov
+RUN: not LLVMFuzzer-NullDerefTest -dump_coverage=1 2>&1 | FileCheck %s
+RUN: ls *.sancov | xargs sancov -covered-functions LLVMFuzzer-NullDerefTest* | FileCheck %s --check-prefix=SANCOV
+RUN: LLVMFuzzer-DSOTest -dump_coverage=1 -runs=0 2>&1 | FileCheck %s --check-prefix=DSO
+RUN: not LLVMFuzzer-NullDerefTest -dump_coverage=0 2>&1 | FileCheck %s --check-prefix=NOCOV
 CHECK: SanitizerCoverage: ./LLVMFuzzer-NullDerefTest.{{.*}}.sancov {{.*}} PCs written

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D29532.87077.patch
Type: text/x-patch
Size: 1207 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170204/d8a4ffae/attachment.bin>

More information about the llvm-commits mailing list