From c45edd611595cf03848cf14943d0d44bb297c786 Mon Sep 17 00:00:00 2001 From: Lucas Di Pentima Date: Tue, 9 Jul 2019 18:23:51 -0300 Subject: [PATCH] 15318: Updates go components' tests to consider the req-ids. Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima --- lib/controller/federation_test.go | 6 +++--- lib/dispatchcloud/container/queue_test.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/controller/federation_test.go b/lib/controller/federation_test.go index f7735a3053..169b1f7961 100644 --- a/lib/controller/federation_test.go +++ b/lib/controller/federation_test.go @@ -134,7 +134,7 @@ func (s *FederationSuite) TestNoAuth(c *check.C) { req := httptest.NewRequest("GET", "/arvados/v1/workflows/"+arvadostest.WorkflowWithDefinitionYAMLUUID, nil) resp := s.testRequest(req).Result() c.Check(resp.StatusCode, check.Equals, http.StatusUnauthorized) - s.checkJSONErrorMatches(c, resp, `Not logged in`) + s.checkJSONErrorMatches(c, resp, `Not logged in.*`) } func (s *FederationSuite) TestBadAuth(c *check.C) { @@ -142,7 +142,7 @@ func (s *FederationSuite) TestBadAuth(c *check.C) { req.Header.Set("Authorization", "Bearer aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") resp := s.testRequest(req).Result() c.Check(resp.StatusCode, check.Equals, http.StatusUnauthorized) - s.checkJSONErrorMatches(c, resp, `Not logged in`) + s.checkJSONErrorMatches(c, resp, `Not logged in.*`) } func (s *FederationSuite) TestNoAccess(c *check.C) { @@ -150,7 +150,7 @@ func (s *FederationSuite) TestNoAccess(c *check.C) { req.Header.Set("Authorization", "Bearer "+arvadostest.SpectatorToken) resp := s.testRequest(req).Result() c.Check(resp.StatusCode, check.Equals, http.StatusNotFound) - s.checkJSONErrorMatches(c, resp, `.*not found`) + s.checkJSONErrorMatches(c, resp, `.*not found.*`) } func (s *FederationSuite) TestGetUnknownRemote(c *check.C) { diff --git a/lib/dispatchcloud/container/queue_test.go b/lib/dispatchcloud/container/queue_test.go index daf7977ad5..e817a0cc7b 100644 --- a/lib/dispatchcloud/container/queue_test.go +++ b/lib/dispatchcloud/container/queue_test.go @@ -74,7 +74,7 @@ func (suite *IntegrationSuite) TestGetLockUnlockCancel(c *check.C) { defer wg.Done() err := cq.Unlock(uuid) c.Check(err, check.NotNil) - c.Check(err, check.ErrorMatches, ".*cannot unlock when Queued*.") + c.Check(err, check.ErrorMatches, ".*cannot unlock when Queued.*") err = cq.Lock(uuid) c.Check(err, check.IsNil) -- 2.30.2