<div dir="ltr">AFAIK this is the only solution when you have a file where some tests require one thing but another tests requires another thing. You have to split them out into different file so each file can have it's own REQUIRES line. kcc@, do you know of a better way? Assuming this is the only way, lgtm but wait for kcc.</div><br><div class="gmail_quote"><div dir="ltr">On Wed, Feb 1, 2017 at 1:32 PM Marcos Pividori via Phabricator <<a href="mailto:reviews@reviews.llvm.org">reviews@reviews.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">mpividori created this revision.<br class="gmail_msg">
<br class="gmail_msg">
<a href="https://reviews.llvm.org/D29420" rel="noreferrer" class="gmail_msg" target="_blank">https://reviews.llvm.org/D29420</a><br class="gmail_msg">
<br class="gmail_msg">
Files:<br class="gmail_msg">
lib/Fuzzer/test/merge-posix.test<br class="gmail_msg">
lib/Fuzzer/test/merge.test<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
Index: lib/Fuzzer/test/merge.test<br class="gmail_msg">
===================================================================<br class="gmail_msg">
--- lib/Fuzzer/test/merge.test<br class="gmail_msg">
+++ lib/Fuzzer/test/merge.test<br class="gmail_msg">
@@ -45,14 +45,6 @@<br class="gmail_msg">
RUN: LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 -max_len=5 2>&1 | FileCheck %s --check-prefix=MERGE_LEN5<br class="gmail_msg">
MERGE_LEN5: MERGE-OUTER: succesfull in 1 attempt(s)<br class="gmail_msg">
<br class="gmail_msg">
-# Check that we honor TMPDIR<br class="gmail_msg">
-RUN: TMPDIR=DIR_DOES_NOT_EXIST not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=TMPDIR<br class="gmail_msg">
-TMPDIR: MERGE-OUTER: failed to write to the control file: DIR_DOES_NOT_EXIST/libFuzzerTemp<br class="gmail_msg">
-<br class="gmail_msg">
-# Check that we can report an error if file size exceeded<br class="gmail_msg">
-RUN: (ulimit -f 1; not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=SIGXFSZ)<br class="gmail_msg">
-SIGXFSZ: ERROR: libFuzzer: file size exceeded<br class="gmail_msg">
-<br class="gmail_msg">
RUN: rm -rf %tmp/T1/* %tmp/T2/*<br class="gmail_msg">
RUN: not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=EMPTY<br class="gmail_msg">
EMPTY: MERGE-OUTER: zero succesfull attempts, exiting<br class="gmail_msg">
Index: lib/Fuzzer/test/merge-posix.test<br class="gmail_msg">
===================================================================<br class="gmail_msg">
--- /dev/null<br class="gmail_msg">
+++ lib/Fuzzer/test/merge-posix.test<br class="gmail_msg">
@@ -0,0 +1,17 @@<br class="gmail_msg">
+CHECK: BINGO<br class="gmail_msg">
+<br class="gmail_msg">
+RUN: rm -rf %tmp/T1 %tmp/T2<br class="gmail_msg">
+RUN: mkdir -p %tmp/T1 %tmp/T2<br class="gmail_msg">
+RUN: echo F..... > %tmp/T1/1<br class="gmail_msg">
+RUN: echo .U.... > %tmp/T1/2<br class="gmail_msg">
+RUN: echo ..Z... > %tmp/T1/3<br class="gmail_msg">
+<br class="gmail_msg">
+# Check that we honor TMPDIR<br class="gmail_msg">
+RUN: TMPDIR=DIR_DOES_NOT_EXIST not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=TMPDIR<br class="gmail_msg">
+TMPDIR: MERGE-OUTER: failed to write to the control file: DIR_DOES_NOT_EXIST/libFuzzerTemp<br class="gmail_msg">
+<br class="gmail_msg">
+# Check that we can report an error if file size exceeded<br class="gmail_msg">
+RUN: (ulimit -f 1; not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=SIGXFSZ)<br class="gmail_msg">
+SIGXFSZ: ERROR: libFuzzer: file size exceeded<br class="gmail_msg">
+<br class="gmail_msg">
+REQUIRES: posix<br class="gmail_msg">
<br class="gmail_msg">
<br class="gmail_msg">
</blockquote></div>