Refactor and modularize analytics on the client

Этот коммит содержится в:
JoramWilander
2016-02-25 12:32:46 -05:00
родитель 8aa4e28932
Коммит 8239c68cf3
28 изменённых файлов: 1416 добавлений и 1076 удалений

Просмотреть файл

@@ -254,6 +254,16 @@ func TestGetTeamAnalyticsStandard(t *testing.T) {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Name != "team_count" {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Value == 0 {
t.Log(rows.ToJson())
t.Fatal()
}
}
if result, err := Client.GetSystemAnalytics("standard"); err != nil {
@@ -300,6 +310,16 @@ func TestGetTeamAnalyticsStandard(t *testing.T) {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Name != "team_count" {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Value == 0 {
t.Log(rows.ToJson())
t.Fatal()
}
}
}
@@ -469,6 +489,26 @@ func TestGetTeamAnalyticsExtra(t *testing.T) {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Name != "command_count" {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Value != 0 {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[5].Name != "session_count" {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[5].Value == 0 {
t.Log(rows.ToJson())
t.Fatal()
}
}
if result, err := Client.GetSystemAnalytics("extra_counts"); err != nil {
@@ -500,5 +540,15 @@ func TestGetTeamAnalyticsExtra(t *testing.T) {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[4].Name != "command_count" {
t.Log(rows.ToJson())
t.Fatal()
}
if rows[5].Name != "session_count" {
t.Log(rows.ToJson())
t.Fatal()
}
}
}