From 2880e7bd5e680d2c4b77697066f0f2d50b4d1d5b Mon Sep 17 00:00:00 2001 From: 0xdev22 Date: Thu, 25 Apr 2024 17:26:14 -0400 Subject: [PATCH] Fix issues from PR review --- internal/controllers/user_integrations_controller_test.go | 4 ++-- internal/services/tesla_fleet_api_service.go | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/internal/controllers/user_integrations_controller_test.go b/internal/controllers/user_integrations_controller_test.go index 1ad209f61..91fc51b33 100644 --- a/internal/controllers/user_integrations_controller_test.go +++ b/internal/controllers/user_integrations_controller_test.go @@ -1106,13 +1106,13 @@ func (s *UserIntegrationsControllerTestSuite) TestGetUserDeviceIntegration() { res, err := s.app.Test(request, 60*1000) s.Assert().NoError(err) - s.Require().True(res.StatusCode == fiber.StatusOK) + s.Require().Equal(res.StatusCode, fiber.StatusOK) body, _ := io.ReadAll(res.Body) defer res.Body.Close() actual := GetUserDeviceIntegrationResponse{} - s.Assert().NoError(json.Unmarshal(body, &actual)) + s.Require().NoError(json.Unmarshal(body, &actual)) s.Assert().True(actual.Tesla.IsVirtualTokenConnected) s.Assert().Equal(models.UserDeviceAPIIntegrationStatusActive, actual.Status) diff --git a/internal/services/tesla_fleet_api_service.go b/internal/services/tesla_fleet_api_service.go index 4bc5937c7..e90281349 100644 --- a/internal/services/tesla_fleet_api_service.go +++ b/internal/services/tesla_fleet_api_service.go @@ -186,7 +186,6 @@ func (t *teslaFleetAPIService) VirtualTokenConnectionStatus(ctx context.Context, jsonBody := fmt.Sprintf(`{"vins": [%q]}`, vin) body := strings.NewReader(jsonBody) - // bytes.NewReader(jsonBody) resp, err := t.performRequest(ctx, url, token, http.MethodPost, body) if err != nil {