aboutsummaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xt/t7500-commit-template-squash-signoff.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/t/t7500-commit-template-squash-signoff.sh b/t/t7500-commit-template-squash-signoff.sh
index 4922543256..a85229e556 100755
--- a/t/t7500-commit-template-squash-signoff.sh
+++ b/t/t7500-commit-template-squash-signoff.sh
@@ -46,6 +46,14 @@ test_expect_success 'nonexistent template file in config should return error' '
)
'
+test_expect_success 'nonexistent optional template file in config' '
+ test_config commit.template ":(optional)$PWD"/notexist &&
+ GIT_EDITOR="echo hello >" git commit --allow-empty &&
+ git cat-file commit HEAD | sed -e "1,/^$/d" >actual &&
+ echo hello >expect &&
+ test_cmp expect actual
+'
+
# From now on we'll use a template file that exists.
TEMPLATE="$PWD"/template