summaryrefslogtreecommitdiffstats
path: root/store/storetest/channel_store.go
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2018-06-29 18:13:13 -0400
committerJesús Espino <jespinog@gmail.com>2018-06-30 00:13:13 +0200
commit2362a5b7f7c2b4bf2b35b104e8616d847b33b0be (patch)
treebaba1dba36f06308524e56c82df2ff7264cba50b /store/storetest/channel_store.go
parent4245797cb23b3f9dc99ff556a5ee22c4e14140bc (diff)
downloadchat-2362a5b7f7c2b4bf2b35b104e8616d847b33b0be.tar.gz
chat-2362a5b7f7c2b4bf2b35b104e8616d847b33b0be.tar.bz2
chat-2362a5b7f7c2b4bf2b35b104e8616d847b33b0be.zip
Ignore | characters in postgres channel search (#9019)
Diffstat (limited to 'store/storetest/channel_store.go')
-rw-r--r--store/storetest/channel_store.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/store/storetest/channel_store.go b/store/storetest/channel_store.go
index b033e9c98..ccf4b1c59 100644
--- a/store/storetest/channel_store.go
+++ b/store/storetest/channel_store.go
@@ -2028,6 +2028,19 @@ func testChannelStoreSearchInTeam(t *testing.T, ss store.Store) {
t.Fatal("wrong channel returned")
}
}
+
+ if result := <-search(o1.TeamId, "town square |"); result.Err != nil {
+ t.Fatal(result.Err)
+ } else {
+ channels := result.Data.(*model.ChannelList)
+ if len(*channels) != 1 {
+ t.Fatal("should return 1 channel")
+ }
+
+ if (*channels)[0].Name != o9.Name {
+ t.Fatal("wrong channel returned")
+ }
+ }
})
}
}