aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2007-05-29 00:27:24 -0700
committerJunio C Hamano <junkio@cox.net>2007-05-29 00:27:24 -0700
commit79d5576a4f2eada820802d2e7e19226e54f9de5d (patch)
tree1368eb21d31f3bda4823385f98656b9566e0924c /t
parent24a97d84adb649ca5d90c9b1e6d894f4acee1a6b (diff)
parenta192a909c0cdb8ea09b6513c4839fd6762989cb1 (diff)
downloadgit-79d5576a4f2eada820802d2e7e19226e54f9de5d.tar.gz
git-79d5576a4f2eada820802d2e7e19226e54f9de5d.tar.xz
Merge branch 'maint'
* maint: cvsserver: Fix some typos in asciidoc documentation cvsserver: Note that CVS_SERVER can also be specified as method variable cvsserver: Correct inetd.conf example in asciidoc documentation user-manual: fixed typo in example Add test case for $Id$ expanded in the repository git-svn: avoid md5 calculation entirely if SVN doesn't provide one Makefile: Remove git-fsck and git-verify-pack from PROGRAMS Fix stupid typo in lookup_tag() git-gui: Guess our share/git-gui/lib path at runtime if possible Correct key bindings to Control-<foo> git-gui: Tighten internal pattern match for lib/ directory
Diffstat (limited to 't')
-rwxr-xr-xt/t0021-conversion.sh36
1 files changed, 36 insertions, 0 deletions
diff --git a/t/t0021-conversion.sh b/t/t0021-conversion.sh
index 6c26fd829..a839f4e07 100755
--- a/t/t0021-conversion.sh
+++ b/t/t0021-conversion.sh
@@ -45,4 +45,40 @@ test_expect_success check '
test "z$id" = "z$embedded"
'
+# If an expanded ident ever gets into the repository, we want to make sure that
+# it is collapsed before being expanded again on checkout
+test_expect_success expanded_in_repo '
+ {
+ echo "File with expanded keywords"
+ echo "\$Id\$"
+ echo "\$Id:\$"
+ echo "\$Id: 0000000000000000000000000000000000000000 \$"
+ echo "\$Id: NoSpaceAtEnd\$"
+ echo "\$Id:NoSpaceAtFront \$"
+ echo "\$Id:NoSpaceAtEitherEnd\$"
+ echo "\$Id: NoTerminatingSymbol"
+ } > expanded-keywords &&
+
+ {
+ echo "File with expanded keywords"
+ echo "\$Id: 4f21723e7b15065df7de95bd46c8ba6fb1818f4c \$"
+ echo "\$Id: 4f21723e7b15065df7de95bd46c8ba6fb1818f4c \$"
+ echo "\$Id: 4f21723e7b15065df7de95bd46c8ba6fb1818f4c \$"
+ echo "\$Id: 4f21723e7b15065df7de95bd46c8ba6fb1818f4c \$"
+ echo "\$Id: 4f21723e7b15065df7de95bd46c8ba6fb1818f4c \$"
+ echo "\$Id: 4f21723e7b15065df7de95bd46c8ba6fb1818f4c \$"
+ echo "\$Id: NoTerminatingSymbol"
+ } > expected-output &&
+
+ git add expanded-keywords &&
+ git commit -m "File with keywords expanded" &&
+
+ echo "expanded-keywords ident" >> .gitattributes &&
+
+ rm -f expanded-keywords &&
+ git checkout -- expanded-keywords &&
+ cat expanded-keywords &&
+ cmp expanded-keywords expected-output
+'
+
test_done