summaryrefslogtreecommitdiffstats
path: root/app/team_test.go
diff options
context:
space:
mode:
authorHarrison Healey <harrisonmhealey@gmail.com>2017-04-04 11:54:52 -0400
committerJoram Wilander <jwawilander@gmail.com>2017-04-04 11:54:52 -0400
commitc7bdce8a6641ed8d361a43b6004a351535c78423 (patch)
treef42d32d8a4d0cd4f702644dcb6a594f905f3f771 /app/team_test.go
parent3a79e451ffe3ffe618311ee15b02dbebde6a77b0 (diff)
downloadchat-c7bdce8a6641ed8d361a43b6004a351535c78423.tar.gz
chat-c7bdce8a6641ed8d361a43b6004a351535c78423.tar.bz2
chat-c7bdce8a6641ed8d361a43b6004a351535c78423.zip
PLT-5900 Removed automatic configuration of SiteURL (#5952)
* Revert "PLT-5765 Passed SiteURL to SendNotifications (#5705)" This reverts commit a8e68bd8905972ae59de90fa33d5b3e3c274dc47. * Removed automatic configuration of SiteURL * Reverted unintentional config changes * Updated help text * Added link to docs in Site URL warning * Fixed merge conflict
Diffstat (limited to 'app/team_test.go')
-rw-r--r--app/team_test.go11
1 files changed, 5 insertions, 6 deletions
diff --git a/app/team_test.go b/app/team_test.go
index 75f09f1ca..64af0c4af 100644
--- a/app/team_test.go
+++ b/app/team_test.go
@@ -8,7 +8,6 @@ import (
"testing"
"github.com/mattermost/platform/model"
- "github.com/mattermost/platform/utils"
)
func TestCreateTeam(t *testing.T) {
@@ -43,12 +42,12 @@ func TestCreateTeamWithUser(t *testing.T) {
Type: model.TEAM_OPEN,
}
- if _, err := CreateTeamWithUser(team, th.BasicUser.Id, utils.GetSiteURL()); err != nil {
+ if _, err := CreateTeamWithUser(team, th.BasicUser.Id); err != nil {
t.Log(err)
t.Fatal("Should create a new team with existing user")
}
- if _, err := CreateTeamWithUser(team, model.NewId(), utils.GetSiteURL()); err == nil {
+ if _, err := CreateTeamWithUser(team, model.NewId()); err == nil {
t.Fatal("Should not create a new team - user does not exist")
}
@@ -64,7 +63,7 @@ func TestCreateTeamWithUser(t *testing.T) {
}
//Fail to create a team with user when user has set email without domain
- if _, err := CreateTeamWithUser(team2, ruser.Id, utils.GetSiteURL()); err == nil {
+ if _, err := CreateTeamWithUser(team2, ruser.Id); err == nil {
t.Log(err.Message)
t.Fatal("Should not create a team with user when user has set email without domain")
} else {
@@ -96,7 +95,7 @@ func TestAddUserToTeam(t *testing.T) {
user := model.User{Email: strings.ToLower(model.NewId()) + "success+test@example.com", Nickname: "Darth Vader", Username: "vader" + model.NewId(), Password: "passwd1", AuthService: ""}
ruser, _ := CreateUser(&user)
- if _, err := AddUserToTeam(th.BasicTeam.Id, ruser.Id, utils.GetSiteURL()); err != nil {
+ if _, err := AddUserToTeam(th.BasicTeam.Id, ruser.Id); err != nil {
t.Log(err)
t.Fatal("Should add user to the team")
}
@@ -108,7 +107,7 @@ func TestAddUserToTeamByTeamId(t *testing.T) {
user := model.User{Email: strings.ToLower(model.NewId()) + "success+test@example.com", Nickname: "Darth Vader", Username: "vader" + model.NewId(), Password: "passwd1", AuthService: ""}
ruser, _ := CreateUser(&user)
- if err := AddUserToTeamByTeamId(th.BasicTeam.Id, ruser, utils.GetSiteURL()); err != nil {
+ if err := AddUserToTeamByTeamId(th.BasicTeam.Id, ruser); err != nil {
t.Log(err)
t.Fatal("Should add user to the team")
}