1# This tests that the reproducer can deal with relative files. We create a
2# binary in a subdirectory and pass its relative path to LLDB.
3
4# RUN: echo "CHECK: %t" > %t.check
5
6# RUN: rm -rf %t.repro
7# RUN: mkdir -p %t.repro
8# RUN: mkdir -p %t
9# RUN: mkdir -p %t/binary
10# RUN: cd %t
11# RUN: %clang_host %S/Inputs/simple.c -g -o binary/reproducer.out
12# RUN: %lldb -x -b -s %S/Inputs/WorkingDir.in --capture --capture-path %t.repro binary/reproducer.out
13# RUN: rm -rf %t/binary
14
15# RUN: cat %t.repro/cwd.txt | FileCheck %t.check
16
17# Make sure the current working directory is recorded even when it's not
18# referenced.
19
20# RUN: rm -rf %t.repro
21# RUN: rm -rf %t
22# RUN: mkdir -p %t/probably_unique
23# RUN: touch %t/probably_unique/dont_include_me
24# RUN: cd %t/probably_unique
25# RUN: %lldb -x -b -o 'reproducer generate' --capture --capture-path %t.repro
26# RUN: cat %t.repro/cwd.txt | FileCheck %s
27# CHECK: probably_unique
28# RUN: cat %t.repro/files.yaml | FileCheck %s --check-prefix VFS
29# VFS: probably_unique
30# VFS-NOT: dont_include_me
31