| 1 |
set test "Print filename with -H" |
| 2 |
|
| 3 |
clear_pdfdir |
| 4 |
set pdf [mkpdf foo "foobar"] |
| 5 |
|
| 6 |
pdfgrep_expect -H foo $pdf \ |
| 7 |
"$pdf:foobar" |
| 8 |
|
| 9 |
expect_exit_status 0 |
| 10 |
|
| 11 |
######################################## |
| 12 |
|
| 13 |
set test "Print filename with multiple files" |
| 14 |
|
| 15 |
set pdf2 [mkpdf bar "barfoo"] |
| 16 |
|
| 17 |
pdfgrep_expect foo $pdf $pdf2 \ |
| 18 |
"$pdf:foobar |
| 19 |
$pdf2:barfoo" |
| 20 |
|
| 21 |
expect_exit_status 0 |
| 22 |
|
| 23 |
######################################## |
| 24 |
|
| 25 |
set test "Print filename with multiple files and -r" |
| 26 |
|
| 27 |
pdfgrep_expect -r foo $pdfdir \ |
| 28 |
"($pdf:foobar|$pdf2:barfoo) |
| 29 |
($pdf:foobar|$pdf2:barfoo)" |
| 30 |
|
| 31 |
expect_exit_status 0 |
| 32 |
|
| 33 |
######################################## |
| 34 |
|
| 35 |
set test "Don't print filename with -h" |
| 36 |
|
| 37 |
pdfgrep_expect -h foo $pdf $pdf2 \ |
| 38 |
"foobar |
| 39 |
barfoo" |
| 40 |
|
| 41 |
expect_exit_status 0 |