summaryrefslogtreecommitdiffstats
path: root/api/command_test.go
diff options
context:
space:
mode:
authorChris <ccbrown112@gmail.com>2017-10-16 08:09:43 -0700
committerJoram Wilander <jwawilander@gmail.com>2017-10-16 11:09:43 -0400
commit34285d8cca93fc0f473636e78680fade03f26bda (patch)
treeb8274ed8d17e5dc63ac36aadac7e7299635d2b43 /api/command_test.go
parentadb2b1d6eddabea803af8fa6cf53a75c98694427 (diff)
downloadchat-34285d8cca93fc0f473636e78680fade03f26bda.tar.gz
chat-34285d8cca93fc0f473636e78680fade03f26bda.tar.bz2
chat-34285d8cca93fc0f473636e78680fade03f26bda.zip
parallel tests (#7629)
Diffstat (limited to 'api/command_test.go')
-rw-r--r--api/command_test.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/api/command_test.go b/api/command_test.go
index 9d146b189..948193852 100644
--- a/api/command_test.go
+++ b/api/command_test.go
@@ -4,6 +4,7 @@
package api
import (
+ "fmt"
"strings"
"testing"
"time"
@@ -257,7 +258,7 @@ func TestTestCommand(t *testing.T) {
*utils.Cfg.ServiceSettings.AllowedUntrustedInternalConnections = "localhost"
cmd1 := &model.Command{
- URL: "http://localhost" + *utils.Cfg.ServiceSettings.ListenAddress + model.API_URL_SUFFIX_V3 + "/teams/command_test",
+ URL: fmt.Sprintf("http://localhost:%v", th.App.Srv.ListenAddr.Port) + model.API_URL_SUFFIX_V3 + "/teams/command_test",
Method: model.COMMAND_METHOD_POST,
Trigger: "testcommand",
}
@@ -290,7 +291,7 @@ func TestTestCommand(t *testing.T) {
}
cmd2 := &model.Command{
- URL: "http://localhost" + *utils.Cfg.ServiceSettings.ListenAddress + model.API_URL_SUFFIX_V3 + "/teams/command_test",
+ URL: fmt.Sprintf("http://localhost:%v", th.App.Srv.ListenAddr.Port) + model.API_URL_SUFFIX_V3 + "/teams/command_test",
Method: model.COMMAND_METHOD_GET,
Trigger: "test2",
}