// GetServerTime calls the GetTime method of the messaging, parses the response to get the
// value and return it.
func GetServerTime(c context.Context, w http.ResponseWriter, r *http.Request, pubnubInstance *messaging.Pubnub, t *testing.T, testName string) int64 {
	returnTimeChannel := make(chan []byte)
	errorChannel := make(chan []byte)

	//go pubnubInstance.GetTime(returnTimeChannel, errorChannel)
	go pubnubInstance.GetTime(c, w, r, returnTimeChannel, errorChannel)
	return ParseServerTimeResponse(returnTimeChannel, t, testName)
}