3 RUN: %cpp_compiler %S/NullDerefTest.cpp -o %t-NullDerefTest
4 RUN: %cpp_compiler %S/DSO1.cpp -fPIC -shared -o %t-DSO1.so
5 RUN: %cpp_compiler %S/DSO2.cpp -fPIC -shared -o %t-DSO2.so
6 RUN: %cpp_compiler %S/DSOTestMain.cpp %S/DSOTestExtra.cpp -L. %t-DSO1.so %t-DSO2.so -o %t-DSOTest
9 CHECK-DAG: COVERED: {{.*}}in LLVMFuzzerTestOneInput {{.*}}NullDerefTest.cpp:13
10 CHECK-DAG: COVERED: {{.*}}in LLVMFuzzerTestOneInput {{.*}}NullDerefTest.cpp:14
11 CHECK-DAG: COVERED: {{.*}}in LLVMFuzzerTestOneInput {{.*}}NullDerefTest.cpp:16
12 CHECK-DAG: COVERED: {{.*}}in LLVMFuzzerTestOneInput {{.*}}NullDerefTest.cpp:19
13 CHECK: COVERED_DIRS: {{.*}}lib{{[/\\]}}Fuzzer{{[/\\]}}test
14 RUN: not %t-NullDerefTest -print_coverage=1 2>&1 | FileCheck %s
16 RUN: %t-DSOTest -print_coverage=1 -runs=0 2>&1 | FileCheck %s --check-prefix=DSO
18 DSO-DAG: COVERED:{{.*}}DSO1{{.*}}DSO1.cpp
19 DSO-DAG: COVERED:{{.*}}DSO2{{.*}}DSO2.cpp
20 DSO-DAG: COVERED:{{.*}}LLVMFuzzerTestOneInput{{.*}}DSOTestMain
21 DSO-DAG: UNCOVERED_LINE:{{.*}}DSO1{{.*}}DSO1.cpp
22 DSO-DAG: UNCOVERED_LINE:{{.*}}DSO2{{.*}}DSO2.cpp
23 DSO-DAG: UNCOVERED_FUNC: in Uncovered1
24 DSO-DAG: UNCOVERED_FUNC: in Uncovered2
25 DSO-DAG: UNCOVERED_LINE: in LLVMFuzzerTestOneInput
26 DSO-DAG: UNCOVERED_FILE:{{.*}}DSOTestExtra.cpp