This reverts r374324 (git commit 62808631ac)
I changed the test to not rely on finding the sequence "clang, test,
CoverageMapping" in the CWD used to run the test. Instead it makes its
own internal directory hierarchy of foo/bar/baz and looks for that.
llvm-svn: 374403
17 lines
796 B
C++
17 lines
796 B
C++
// %s expands to an absolute path, so to test relative paths we need to create a
|
|
// clean directory, put the source there, and cd into it.
|
|
// RUN: rm -rf %t
|
|
// RUN: mkdir -p %t/foo/bar/baz
|
|
// RUN: cp %s %t/foo/bar/baz/debug-dir.cpp
|
|
// RUN: cd %t/foo/bar
|
|
|
|
// RUN: %clang_cc1 -fprofile-instrument=clang -fcoverage-mapping -emit-llvm -main-file-name debug-dir.cpp baz/debug-dir.cpp -o - | FileCheck -check-prefix=ABSOLUTE %s
|
|
//
|
|
// ABSOLUTE: @__llvm_coverage_mapping = {{.*"\\01.*foo.*bar.*baz.*debug-dir\.cpp}}
|
|
|
|
// RUN: %clang_cc1 -fprofile-instrument=clang -fcoverage-mapping -emit-llvm -main-file-name debug-dir.cpp baz/debug-dir.cpp -fdebug-compilation-dir . -o - | FileCheck -check-prefix=RELATIVE %s
|
|
//
|
|
// RELATIVE: @__llvm_coverage_mapping = {{.*"\\01[^/]*baz.*debug-dir\.cpp}}
|
|
|
|
void f1() {}
|