xref: /llvm-project/clang/test/VFS/relative-path-errors.c (revision 86e2af8043c7728710a711b623f27425801a36c3)
1 // RUN: mkdir -p %t
2 // RUN: cd %t
3 // RUN: cp %s main.c
4 // RUN: not %clang_cc1 main.c 2>&1 | FileCheck %s
5 // RUN: echo '{"roots": [],"version": 0}' > %t.yaml
6 // RUN: not %clang_cc1 -ivfsoverlay %t.yaml main.c 2>&1 | FileCheck %s
7 // RUN: echo '{"version": 0,"roots":[{"type":"directory","name":"%/t","contents":[{"type":"file","name":"vfsname", "external-contents":"main.c"}]}]}' > %t.yaml
8 // RUN: not %clang_cc1 -ivfsoverlay %t.yaml vfsname 2>&1 | FileCheck %s
9 
10 // CHECK: {{^}}main.c:[[# @LINE + 1]]:1: error:
11 foobarbaz
12