summaryrefslogtreecommitdiff
path: root/t/t7005-editor.sh
diff options
context:
space:
mode:
Diffstat (limited to 't/t7005-editor.sh')
-rwxr-xr-xt/t7005-editor.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/t/t7005-editor.sh b/t/t7005-editor.sh
index b647957d75..a95fe19d8c 100755
--- a/t/t7005-editor.sh
+++ b/t/t7005-editor.sh
@@ -42,6 +42,16 @@ test_expect_success 'dumb should error out when falling back on vi' '
fi
'
+test_expect_success 'dumb should prefer EDITOR to VISUAL' '
+
+ EDITOR=./e-EDITOR.sh &&
+ VISUAL=./e-VISUAL.sh &&
+ export EDITOR VISUAL &&
+ git commit --amend &&
+ test "$(git show -s --format=%s)" = "Edited by EDITOR"
+
+'
+
TERM=vt100
export TERM
for i in vi EDITOR VISUAL core_editor GIT_EDITOR