From 1aa0b4567fc1849712471e129b868927f400f773 Mon Sep 17 00:00:00 2001 From: Oleg Pudeyev Date: Thu, 8 Nov 2012 10:23:28 -0500 Subject: [PATCH] [ticket/11174] More tests. PHPBB3-11174 --- tests/search/native_test.php | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/tests/search/native_test.php b/tests/search/native_test.php index 15b4644498..8638a914ba 100644 --- a/tests/search/native_test.php +++ b/tests/search/native_test.php @@ -76,6 +76,29 @@ class phpbb_search_native_test extends phpbb_database_test_case array(1, 2), array(), ), + // leading, trailing and multiple spaces + array( + ' foo bar ', + 'all', + true, + array(1, 2), + array(), + ), + // words too short + array( + 'f', + 'all', + false, + array(), + array(), + ), + array( + 'f o o', + 'all', + false, + array(), + array(), + ), array( 'foo -bar', 'all', @@ -83,6 +106,7 @@ class phpbb_search_native_test extends phpbb_database_test_case array(1), array(2), ), + // all negative array( '-foo', 'all',