mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-01 05:01:59 +01:00
[libFuzzer] Isolate merge tests that require posix.
Differential Revision: https://reviews.llvm.org/D29420 llvm-svn: 293828
This commit is contained in:
parent
d8cbaf72a3
commit
87c9cfa307
23
lib/Fuzzer/test/merge-posix.test
Normal file
23
lib/Fuzzer/test/merge-posix.test
Normal file
@ -0,0 +1,23 @@
|
||||
REQUIRES: posix
|
||||
|
||||
RUN: rm -rf %tmp/T1 %tmp/T2
|
||||
RUN: mkdir -p %tmp/T1 %tmp/T2
|
||||
|
||||
RUN: echo F..... > %tmp/T1/1
|
||||
RUN: echo .U.... > %tmp/T1/2
|
||||
RUN: echo ..Z... > %tmp/T1/3
|
||||
|
||||
RUN: echo .....F > %tmp/T2/1
|
||||
RUN: echo ....U. > %tmp/T2/2
|
||||
RUN: echo ...Z.. > %tmp/T2/3
|
||||
RUN: echo ...Z.. > %tmp/T2/4
|
||||
RUN: echo ....E. > %tmp/T2/5
|
||||
RUN: echo .....R > %tmp/T2/6
|
||||
|
||||
# Check that we can report an error if file size exceeded
|
||||
RUN: (ulimit -f 1; not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=SIGXFSZ)
|
||||
SIGXFSZ: ERROR: libFuzzer: file size exceeded
|
||||
|
||||
# Check that we honor TMPDIR
|
||||
RUN: TMPDIR=DIR_DOES_NOT_EXIST not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=TMPDIR
|
||||
TMPDIR: MERGE-OUTER: failed to write to the control file: DIR_DOES_NOT_EXIST/libFuzzerTemp
|
@ -45,14 +45,6 @@ MERGE_WITH_CRASH: MERGE-OUTER: 3 new files
|
||||
RUN: LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 -max_len=5 2>&1 | FileCheck %s --check-prefix=MERGE_LEN5
|
||||
MERGE_LEN5: MERGE-OUTER: succesfull in 1 attempt(s)
|
||||
|
||||
# Check that we honor TMPDIR
|
||||
RUN: TMPDIR=DIR_DOES_NOT_EXIST not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=TMPDIR
|
||||
TMPDIR: MERGE-OUTER: failed to write to the control file: DIR_DOES_NOT_EXIST/libFuzzerTemp
|
||||
|
||||
# Check that we can report an error if file size exceeded
|
||||
RUN: (ulimit -f 1; not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=SIGXFSZ)
|
||||
SIGXFSZ: ERROR: libFuzzer: file size exceeded
|
||||
|
||||
RUN: rm -rf %tmp/T1/* %tmp/T2/*
|
||||
RUN: not LLVMFuzzer-FullCoverageSetTest -merge=1 %tmp/T1 %tmp/T2 2>&1 | FileCheck %s --check-prefix=EMPTY
|
||||
EMPTY: MERGE-OUTER: zero succesfull attempts, exiting
|
||||
|
Loading…
x
Reference in New Issue
Block a user