Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Heidelberg <markus.heidelberg@web.de>2009-10-28 15:24:30 +0300
committerJunio C Hamano <gitster@pobox.com>2009-10-30 19:42:52 +0300
commit168eff3c802a47a4e8a97b2ec70d86e5f605a012 (patch)
treeda6835a3f0d38c031b4fe8302bb0a8752f83c7db /t/t4034-diff-words.sh
parent78d553b7d7b269bb22ebd8b1198657c37484a3a0 (diff)
t4034-diff-words: add a test for word diff without context
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4034-diff-words.sh')
-rwxr-xr-xt/t4034-diff-words.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/t/t4034-diff-words.sh b/t/t4034-diff-words.sh
index 4508effcaa..82240cf44d 100755
--- a/t/t4034-diff-words.sh
+++ b/t/t4034-diff-words.sh
@@ -68,6 +68,26 @@ cat > expect <<\EOF
<WHITE>index 330b04f..5ed8eff 100644<RESET>
<WHITE>--- a/pre<RESET>
<WHITE>+++ b/post<RESET>
+<BROWN>@@ -1 +1 @@<RESET>
+<RED>h(4)<RESET><GREEN>h(4),hh[44]<RESET>
+<BROWN>@@ -3,0 +4,4 @@ a = b + c<RESET>
+
+<GREEN>aa = a<RESET>
+
+<GREEN>aeff = aeff * ( aaa )<RESET>
+EOF
+
+test_expect_failure 'word diff without context' '
+
+ word_diff --color-words --unified=0
+
+'
+
+cat > expect <<\EOF
+<WHITE>diff --git a/pre b/post<RESET>
+<WHITE>index 330b04f..5ed8eff 100644<RESET>
+<WHITE>--- a/pre<RESET>
+<WHITE>+++ b/post<RESET>
<BROWN>@@ -1,3 +1,7 @@<RESET>
h(4),<GREEN>hh<RESET>[44]
<RESET>