diff options
| author | Marcos Pividori <mpividori@google.com> | 2017-02-08 00:02:59 +0000 |
|---|---|---|
| committer | Marcos Pividori <mpividori@google.com> | 2017-02-08 00:02:59 +0000 |
| commit | 992e6308a775487d9f2caa5f058327bd23427f1c (patch) | |
| tree | f05e8162c0d6ae1642a3086b6333c45d223ee9e2 | |
| parent | abcdcf9f8662ae8b33ed84ac6404bc6c00cc3143 (diff) | |
| download | bcm5719-llvm-992e6308a775487d9f2caa5f058327bd23427f1c.tar.gz bcm5719-llvm-992e6308a775487d9f2caa5f058327bd23427f1c.zip | |
[libFuzzer] Don't add newline character when using echo in tests.
Add the option "-n", so we don't add a new line character at the end of the file
when using echo. (on Windows this means 2 characters).
Differential Revision: https://reviews.llvm.org/D29536
llvm-svn: 294384
| -rw-r--r-- | llvm/lib/Fuzzer/test/fuzzer-dirs.test | 4 | ||||
| -rw-r--r-- | llvm/lib/Fuzzer/test/minimize_crash.test | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Fuzzer/test/fuzzer-dirs.test b/llvm/lib/Fuzzer/test/fuzzer-dirs.test index 63afe8dfcf9..3de64f278f5 100644 --- a/llvm/lib/Fuzzer/test/fuzzer-dirs.test +++ b/llvm/lib/Fuzzer/test/fuzzer-dirs.test @@ -5,9 +5,9 @@ RUN: echo b > %t/SUB1/SUB2/b RUN: echo c > %t/SUB1/SUB2/SUB3/c RUN: LLVMFuzzer-SimpleTest %t/SUB1 -runs=0 2>&1 | FileCheck %s --check-prefix=SUBDIRS SUBDIRS: READ units: 3 -RUN: echo zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz > %t/SUB1/long +RUN: echo -n zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz > %t/SUB1/long RUN: LLVMFuzzer-SimpleTest %t/SUB1 -runs=0 2>&1 | FileCheck %s --check-prefix=LONG -LONG: INFO: -max_len is not provided, using 94 +LONG: INFO: -max_len is not provided, using 93 RUN: rm -rf %t/SUB1 RUN: not LLVMFuzzer-SimpleTest NONEXISTENT_DIR 2>&1 | FileCheck %s --check-prefix=NONEXISTENT_DIR diff --git a/llvm/lib/Fuzzer/test/minimize_crash.test b/llvm/lib/Fuzzer/test/minimize_crash.test index ec54ec59d6d..7d60ea65385 100644 --- a/llvm/lib/Fuzzer/test/minimize_crash.test +++ b/llvm/lib/Fuzzer/test/minimize_crash.test @@ -5,7 +5,7 @@ RUN: LLVMFuzzer-NullDerefTest -minimize_crash=1 not_minimal_crash -max_total_tim CHECK_EXACT: CRASH_MIN: failed to minimize beyond exact_minimized_path (3 bytes), exiting RUN: rm not_minimal_crash minimized-from-* exact_minimized_path -RUN: echo 'abcd*xyz' > not_minimal_crash +RUN: echo -n 'abcd*xyz' > not_minimal_crash RUN: LLVMFuzzer-SingleByteInputTest -minimize_crash=1 not_minimal_crash -artifact_prefix=./ZZZ- -exact_artifact_path=exact_minimized_path 2>&1 | FileCheck %s --check-prefix=MIN1 MIN1: Test unit written to ./ZZZ-minimized-from- MIN1: INFO: The input is small enough, exiting |

