summaryrefslogtreecommitdiff
path: root/fzytest.c
diff options
context:
space:
mode:
authorJohn Hawthorn <john.hawthorn@gmail.com>2014-07-30 04:18:47 -0700
committerJohn Hawthorn <john.hawthorn@gmail.com>2014-07-30 10:25:21 -0700
commitdeee6d505299c0504dd6b40cf2669b18068d3c95 (patch)
tree84e234e5648d23ffac78821dd044a42380cf7c1a /fzytest.c
parentb76c67f554085652e4128e2ea8e85f24fd26ba17 (diff)
Lesser penalty for leading and trailing gaps
Diffstat (limited to 'fzytest.c')
-rw-r--r--fzytest.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fzytest.c b/fzytest.c
index 028f8d6..1db3009 100644
--- a/fzytest.c
+++ b/fzytest.c
@@ -44,6 +44,10 @@ int test_scoring(){
/* Prefer shorter matches */
assert(match("test", "tests") > match("test", "testing"));
+ /* Prefer shorter matches */
+ assert(match("abc", " a b c ") > match("abc", " a b c "));
+ assert(match("abc", " a b c ") > match("abc", " a b c "));
+
return 0;
}