diff options
| author | Junegunn Choi <junegunn.c@gmail.com> | 2016-05-13 00:36:13 +0900 |
|---|---|---|
| committer | Junegunn Choi <junegunn.c@gmail.com> | 2016-05-13 00:43:50 +0900 |
| commit | dd4be1da380724cdb91daccab8978ed50d7ae6ab (patch) | |
| tree | b8f5b341213fef2339ae1be3852fa541310d3ed1 /src/options_test.go | |
| parent | 66f86e18700f08daa20404d212021da412800d53 (diff) | |
| download | fzf-dd4be1da380724cdb91daccab8978ed50d7ae6ab.tar.gz | |
Allow alt-enter and alt-space for --bind (#571)
Diffstat (limited to 'src/options_test.go')
| -rw-r--r-- | src/options_test.go | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/options_test.go b/src/options_test.go index 81845d29..f3e62f8e 100644 --- a/src/options_test.go +++ b/src/options_test.go @@ -123,14 +123,14 @@ func TestIrrelevantNth(t *testing.T) { } func TestParseKeys(t *testing.T) { - pairs := parseKeyChords("ctrl-z,alt-z,f2,@,Alt-a,!,ctrl-G,J,g", "") + pairs := parseKeyChords("ctrl-z,alt-z,f2,@,Alt-a,!,ctrl-G,J,g,ALT-enter,alt-SPACE", "") check := func(i int, s string) { if pairs[i] != s { t.Errorf("%s != %s", pairs[i], s) } } - if len(pairs) != 9 { - t.Error(9) + if len(pairs) != 11 { + t.Error(11) } check(curses.CtrlZ, "ctrl-z") check(curses.AltZ, "alt-z") @@ -141,6 +141,8 @@ func TestParseKeys(t *testing.T) { check(curses.CtrlA+'g'-'a', "ctrl-G") check(curses.AltZ+'J', "J") check(curses.AltZ+'g', "g") + check(curses.AltEnter, "ALT-enter") + check(curses.AltSpace, "alt-SPACE") // Synonyms pairs = parseKeyChords("enter,Return,space,tab,btab,esc,up,down,left,right", "") |
