Debian Codegraph @

clang/test/Analysis/scan-build/plist_output.test

raw
1 RUN: rm -rf %t.output_dir && mkdir %t.output_dir
2 RUN: %scan-build -plist -o %t.output_dir %clang -S %S/Inputs/single_null_dereference.c \
3 RUN: | FileCheck %s -check-prefix CHECK-STDOUT
4
5 // Test plist output
6
7 CHECK-STDOUT: scan-build: Using '{{.*}}' for static analysis
8 CHECK-STDOUT: scan-build: Analysis run complete.
9 CHECK-STDOUT: scan-build: Analysis results (plist files) deposited in '{{.*}}'
10
11 // We expect a single plist file
12 RUN: ls %t.output_dir/*/ | FileCheck %s -check-prefix CHECK-FILENAMES
13
14 CHECK-FILENAMES: report-{{.*}}.plist
15
16 // The report should describe the issue.
17 RUN: cat %t.output_dir/*/report-*.plist \
18 RUN: | FileCheck %s -check-prefix CHECK-REPORT-PLIST-CONTENTS
19
20 CHECK-REPORT-PLIST-CONTENTS: <key>type</key><string>Dereference of null pointer</string>