2018-09-04 17:08:47 +00:00
|
|
|
# AFL doesn't work on Windows. No reason to test the driver.
|
|
|
|
UNSUPPORTED: freebsd, windows
|
2018-05-24 23:55:52 +00:00
|
|
|
XFAIL: ios
|
2018-05-10 20:37:08 +00:00
|
|
|
RUN: %no_fuzzer_cpp_compiler %S/AFLDriverTest.cpp %libfuzzer_src/afl/afl_driver.cpp -o %t-AFLDriverTest
|
2017-08-21 23:25:50 +00:00
|
|
|
|
|
|
|
; Test that not specifying a stderr file isn't broken.
|
|
|
|
RUN: unset AFL_DRIVER_STDERR_DUPLICATE_FILENAME
|
2018-05-11 21:29:51 +00:00
|
|
|
RUN: %run %t-AFLDriverTest
|
2017-08-21 23:25:50 +00:00
|
|
|
|
|
|
|
; Test that specifying an invalid file causes a crash.
|
2018-05-11 21:29:51 +00:00
|
|
|
RUN: ASAN_OPTIONS= AFL_DRIVER_STDERR_DUPLICATE_FILENAME="%T" not --crash %run %t-AFLDriverTest
|
2017-08-21 23:25:50 +00:00
|
|
|
|
|
|
|
; Test that a file is created when specified as the duplicate stderr.
|
2018-05-11 21:29:51 +00:00
|
|
|
RUN: AFL_DRIVER_STDERR_DUPLICATE_FILENAME=%t %run %t-AFLDriverTest
|
2017-08-21 23:25:50 +00:00
|
|
|
RUN: stat %t
|