summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
author=Corey Hulen <corey@hulen.com>2015-07-05 09:52:23 -0800
committer=Corey Hulen <corey@hulen.com>2015-07-05 09:52:23 -0800
commite01aea78251964006104d4700f010cb150947606 (patch)
tree62482b08cadfbad9cfa209acd3cb0963f2377d3f
parent9261b1ec62e67a4a222e40dfae4376bbeebd3fa0 (diff)
downloadchat-e01aea78251964006104d4700f010cb150947606.tar.gz
chat-e01aea78251964006104d4700f010cb150947606.tar.bz2
chat-e01aea78251964006104d4700f010cb150947606.zip
fixing unit tests
-rw-r--r--api/channel_test.go2
-rw-r--r--api/user_test.go2
2 files changed, 4 insertions, 0 deletions
diff --git a/api/channel_test.go b/api/channel_test.go
index 4dd2afc54..708402ee3 100644
--- a/api/channel_test.go
+++ b/api/channel_test.go
@@ -7,6 +7,7 @@ import (
"github.com/mattermost/platform/model"
"net/http"
"testing"
+ "time"
)
func TestCreateChannel(t *testing.T) {
@@ -687,6 +688,7 @@ func TestUpdateNotifyLevel(t *testing.T) {
data["notify_level"] = model.CHANNEL_NOTIFY_MENTION
timeBeforeUpdate := model.GetMillis()
+ time.Sleep(100 * time.Millisecond)
if _, err := Client.UpdateNotifyLevel(data); err != nil {
t.Fatal(err)
diff --git a/api/user_test.go b/api/user_test.go
index 2a3a3c830..9af9508f2 100644
--- a/api/user_test.go
+++ b/api/user_test.go
@@ -470,6 +470,8 @@ func TestUserUpdate(t *testing.T) {
Client.LoginByEmail(team.Domain, user.Email, "pwd")
+ time.Sleep(100 * time.Millisecond)
+
time2 := model.GetMillis()
user.FullName = "Jim Jimmy"