Let in no ticket as well.
authorStephen Haberman <stephen@exigencecorp.com>
Fri, 20 Jun 2008 00:28:31 +0000 (19:28 -0500)
committerStephen Haberman <stephen@exigencecorp.com>
Fri, 20 Jun 2008 00:28:31 +0000 (19:28 -0500)
client/commit-msg
tests/t1000-commit-msg-ticket-hook.sh

index d617e62..60f638e 100644 (file)
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-grep -i '\(re\|refs\|qa\) #[0-9]\+' "$1" > /dev/null
+grep -i '\(\(re\|refs\|qa\) #[0-9]\+\)\|\(no ticket\)' "$1" > /dev/null
 
 if [ $? -ne 0 ]
 then
index 8ec92d0..033f08a 100644 (file)
@@ -50,5 +50,11 @@ test_expect_success 'accepts with qa' '
        git commit -m "first qa #3200"
 '
 
+test_expect_success 'accepts with no ticket' '
+       echo "$test_name" > file &&
+       git add file &&
+       git commit -m "first no ticket"
+'
+
 test_done