MM-19663 | Migrate brand_test and cluster_test to testify (#12935)
* MM-19663 | Migrate brand_test and cluster_test to testify * Use require.Fail instead of require.FailNow Co-Authored-By: Ben Schumacher <ben.schumacher@mattermost.com>
Этот коммит содержится в:
коммит произвёл
Eli Yukelzon
родитель
a2adf7b3f5
Коммит
cacdda702e
@@ -7,6 +7,7 @@ import (
|
||||
"testing"
|
||||
|
||||
"github.com/mattermost/mattermost-server/model"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
func TestGetClusterStatus(t *testing.T) {
|
||||
@@ -22,9 +23,7 @@ func TestGetClusterStatus(t *testing.T) {
|
||||
infos, resp := th.SystemAdminClient.GetClusterStatus()
|
||||
CheckNoError(t, resp)
|
||||
|
||||
if infos == nil {
|
||||
t.Fatal("should not be nil")
|
||||
}
|
||||
require.NotNil(t, infos, "cluster status should not be nil")
|
||||
})
|
||||
|
||||
t.Run("as restricted system admin", func(t *testing.T) {
|
||||
|
||||
Ссылка в новой задаче
Block a user