summaryrefslogtreecommitdiffstats
path: root/store/sql_post_store_test.go
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2016-05-09 12:00:08 -0400
committerCorey Hulen <corey@hulen.com>2016-05-09 09:00:08 -0700
commit07126101d379b900724c7c5cfc82070b42c235d6 (patch)
tree80b2485b61eb1684cd6127473267af206c3ab1c2 /store/sql_post_store_test.go
parent9e07f4b021b28a3e301359a48cf950298f3e552e (diff)
downloadchat-07126101d379b900724c7c5cfc82070b42c235d6.tar.gz
chat-07126101d379b900724c7c5cfc82070b42c235d6.tar.bz2
chat-07126101d379b900724c7c5cfc82070b42c235d6.zip
Recent mention searches now OR terms instead of AND (#2931)
Diffstat (limited to 'store/sql_post_store_test.go')
-rw-r--r--store/sql_post_store_test.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/store/sql_post_store_test.go b/store/sql_post_store_test.go
index 62db6efb5..3c317b926 100644
--- a/store/sql_post_store_test.go
+++ b/store/sql_post_store_test.go
@@ -767,6 +767,11 @@ func TestPostStoreSearch(t *testing.T) {
if len(r12.Order) != 1 {
t.Fatal("returned wrong search result")
}
+
+ r13 := (<-store.Post().Search(teamId, userId, &model.SearchParams{Terms: "Jersey corey", IsHashtag: false, OrTerms: true})).Data.(*model.PostList)
+ if len(r13.Order) != 2 {
+ t.Fatal("returned wrong search result")
+ }
}
func TestUserCountsWithPostsByDay(t *testing.T) {