aboutsummaryrefslogtreecommitdiffhomepage
path: root/fish_tests.cpp
diff options
context:
space:
mode:
authorGravatar ridiculousfish <corydoras@ridiculousfish.com>2013-01-06 14:10:03 -0800
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2013-01-06 14:10:03 -0800
commit8a357e18669c7eb1f086d69ba770b01b1191e222 (patch)
treeee7949e06f7bbe01da584c9574be647a2ae16f8e /fish_tests.cpp
parentb8135574c389b373de5c6bcff667a9d1d5d22370 (diff)
Add some more tests for autosuggestion combining
Diffstat (limited to 'fish_tests.cpp')
-rw-r--r--fish_tests.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/fish_tests.cpp b/fish_tests.cpp
index 6f1b6887..8bbd23f7 100644
--- a/fish_tests.cpp
+++ b/fish_tests.cpp
@@ -1032,6 +1032,10 @@ static void test_autosuggestion_combining()
// when the last token contains capital letters, we use its case
assert(combine_command_and_autosuggestion(L"alPha", L"alphabeTa") == L"alPhabeTa");
+
+ // if autosuggestion is not longer than input, use the input's case
+ assert(combine_command_and_autosuggestion(L"alpha", L"ALPHAA") == L"ALPHAA");
+ assert(combine_command_and_autosuggestion(L"alpha", L"ALPHA") == L"alpha");
}