summaryrefslogtreecommitdiffstats
path: root/clang-tools-extra/test/clang-include-fixer/yamldb_autodetect.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang-tools-extra/test/clang-include-fixer/yamldb_autodetect.cpp')
-rw-r--r--clang-tools-extra/test/clang-include-fixer/yamldb_autodetect.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/clang-tools-extra/test/clang-include-fixer/yamldb_autodetect.cpp b/clang-tools-extra/test/clang-include-fixer/yamldb_autodetect.cpp
new file mode 100644
index 00000000000..1997390d5a2
--- /dev/null
+++ b/clang-tools-extra/test/clang-include-fixer/yamldb_autodetect.cpp
@@ -0,0 +1,11 @@
+// RUN: mkdir -p %T/foo/bar
+// RUN: cp %p/Inputs/fake_yaml_db.yaml %T/find_all_symbols_db.yaml
+// RUN: cd %T/foo
+// RUN: sed -e 's#//.*$##' %s > bar/test.cpp
+// RUN: clang-include-fixer -db=yaml bar/test.cpp --
+// RUN: FileCheck %s -input-file=bar/test.cpp
+
+// CHECK: #include "foo.h"
+// CHECK: b::a::foo f;
+
+b::a::foo f;
OpenPOWER on IntegriCloud