xref: /llvm-project/llvm/test/tools/llvm-cov/path_equivalence.c (revision 5042e1e56d39a02517abecbe00e72eea698d309a)
1 // RUN: llvm-profdata merge %S/Inputs/path_equivalence.proftext -o %t.profdata
2 // RUN: llvm-cov show %S/Inputs/path_equivalence.covmapping -instr-profile=%t.profdata -path-equivalence=/tmp,%S | FileCheck %s
3 // RUN: llvm-cov show %S/Inputs/path_equivalence.covmapping -instr-profile=%t.profdata -path-equivalence=/tmp/,%S/ | FileCheck %s
main()4 int main() {} // CHECK: [[@LINE]]|      1|int main() {}
5 
6 // RUN: not llvm-cov show --instr-profile=/dev/null -path-equivalence=foo /dev/null 2>&1 | FileCheck --check-prefix=INVALID %s
7 // INVALID: error: -path-equivalence: invalid argument 'foo', must be in format 'from,to'
8 
9 // RUN: not llvm-cov show --instr-profile=/dev/null -path-equivalence=,foo /dev/null 2>&1 | FileCheck --check-prefix=EMPTY_PATH %s
10 // EMPTY_PATH: error: -path-equivalence: invalid argument ',foo', must be in format 'from,to'
11