pull/471/head
Hunter Long 2020-03-31 13:38:43 -07:00
parent 21944e7a94
commit 850a62e81b
2 changed files with 8 additions and 8 deletions

View File

@ -119,7 +119,7 @@ func TestMainApiRoutes(t *testing.T) {
URL: "/api",
Method: "GET",
ExpectedStatus: 200,
ExpectedContains: []string{`"description":"This data is only used to testing"`},
ExpectedContains: []string{`"description":"This is an awesome test"`},
FuncTest: func(t *testing.T) error {
if !core.App.Setup {
return errors.New("database is not setup")

View File

@ -77,7 +77,7 @@ func TestApiServiceRoutes(t *testing.T) {
Name: "Statping Service Failures",
URL: "/api/services/1/failures",
Method: "GET",
ResponseLen: 2,
ResponseLen: 125,
ExpectedStatus: 200,
},
{
@ -102,31 +102,31 @@ func TestApiServiceRoutes(t *testing.T) {
ExpectedStatus: 200,
},
{
Name: "Statping Service 1 Failure Data - 12 Hour",
Name: "Statping Service 1 Failure Data - 24 Hour",
URL: "/api/services/1/failure_data" + startEndQuery + "&group=24h",
Method: "GET",
ResponseLen: 1,
ResponseLen: 4,
ExpectedStatus: 200,
},
{
Name: "Statping Service 1 Failure Data - 12 Hour",
URL: "/api/services/1/failure_data" + startEndQuery + "&group=12h",
Method: "GET",
ResponseLen: 1,
ResponseLen: 7,
ExpectedStatus: 200,
},
{
Name: "Statping Service 1 Failure Data - 1 Hour",
URL: "/api/services/1/failure_data" + startEndQuery + "&group=1h",
Method: "GET",
ResponseLen: 1,
ResponseLen: 72,
ExpectedStatus: 200,
},
{
Name: "Statping Service 1 Failure Data - 15 Minute",
URL: "/api/services/1/failure_data" + startEndQuery + "&group=15m",
Method: "GET",
ResponseLen: 1,
ResponseLen: 124,
ExpectedStatus: 200,
},
{
@ -140,7 +140,7 @@ func TestApiServiceRoutes(t *testing.T) {
Name: "Statping Service 1 Failure Data",
URL: "/api/services/1/failure_data" + startEndQuery,
Method: "GET",
ResponseLen: 1,
ResponseLen: 72,
ExpectedStatus: 200,
},
{