]>
Commit | Line | Data |
---|---|---|
f8b6809d JH |
1 | #!/bin/sh |
2 | ||
3 | test_description='rewrite diff' | |
4 | ||
5 | . ./test-lib.sh | |
6 | ||
7 | test_expect_success setup ' | |
8 | ||
9 | cat ../../COPYING >test && | |
10 | git add test && | |
11 | tr 'a-zA-Z' 'n-za-mN-ZA-M' <../../COPYING >test | |
12 | ||
13 | ' | |
14 | ||
15 | test_expect_success 'detect rewrite' ' | |
16 | ||
17 | actual=$(git diff-files -B --summary test) && | |
18 | expr "$actual" : " rewrite test ([0-9]*%)$" || { | |
19 | echo "Eh? <<$actual>>" | |
20 | false | |
21 | } | |
22 | ||
23 | ' | |
24 | ||
25 | test_done | |
26 |