summaryrefslogtreecommitdiffstats
path: root/api4/cluster_test.go
blob: 8a0ffd1c4b5699b2d1c3b9697b716dc9d16f6fb5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
// Copyright (c) 2017-present Mattermost, Inc. All Rights Reserved.
// See License.txt for license information.

package api4

import (
	"testing"
)

func TestGetClusterStatus(t *testing.T) {
	th := Setup().InitBasic().InitSystemAdmin()
	defer th.TearDown()

	_, resp := th.Client.GetClusterStatus()
	CheckForbiddenStatus(t, resp)

	infos, resp := th.SystemAdminClient.GetClusterStatus()
	CheckNoError(t, resp)

	if infos == nil {
		t.Fatal("should not be nil")
	}
}