aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/bind.expect
diff options
context:
space:
mode:
authorGravatar Chris Pick <chris@chrispick.com>2015-09-03 14:20:08 -0400
committerGravatar Chris Pick <chris@chrispick.com>2015-09-03 15:15:46 -0400
commitab6d9ad521dc6ad96c2a0ea1a2c55702eb5d15c9 (patch)
treed02f577b439208b4e6e2f305cc98a247814981b9 /tests/bind.expect
parenta815e6ca14de7d00a033584789575a2f8caf30be (diff)
Test vi-mode 't' binding
Test 't' binding that contains non-zero arity function (forward-jump) followed by another function (and). This demonstrates the problem in #2357.
Diffstat (limited to 'tests/bind.expect')
-rw-r--r--tests/bind.expect11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/bind.expect b/tests/bind.expect
index 9df5b37c..eedc9079 100644
--- a/tests/bind.expect
+++ b/tests/bind.expect
@@ -37,6 +37,17 @@ expect_prompt -re {\r\nTAXT\r\n} {
puts stderr "Couldn't find expected output 'TAXT'"
}
+# Test 't' binding that contains non-zero arity function (forward-jump) followed
+# by another function (and) https://github.com/fish-shell/fish-shell/issues/2357
+send_line "\033ddiecho TEXT\033hhtTrN"
+expect_prompt -re {\r\nTENT\r\n} {
+ puts "t-binding success"
+} -nounmatched -re {\r\nfail} {
+ puts stderr "t-binding fail"
+} unmatched {
+ puts stderr "Couldn't find expected output 'TENT'"
+}
+
# still in insert mode, switch back to regular key bindings
send_line "set -g fish_key_bindings fish_default_key_bindings"
expect_prompt