diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/xapian.scm | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/xapian.scm b/tests/xapian.scm index 607fdb8..04d1a4d 100644 --- a/tests/xapian.scm +++ b/tests/xapian.scm @@ -68,4 +68,15 @@ given by REPLACEMENT." (time->datestamp 1m) (time->datestamp today)))) +(define tokenize + (@@ (mumi xapian) tokenize)) + +(test-equal "tokenize: keeps phrases intact 1" + (tokenize "subject:\"hello world\" how are you") + '("subject:\"hello world\"" "how" "are" "you")) + +(test-equal "tokenize: keeps phrases intact 2" + (tokenize "subject:\"hello world\" how \"are\" you") + '("subject:\"hello world\"" "how" "\"are\"" "you")) + (test-end "xapian") |