14716: Analyzing integration test fix failure
authorLucas Di Pentima <ldipentima@veritasgenetics.com>
Tue, 6 Aug 2019 13:08:54 +0000 (10:08 -0300)
committerLucas Di Pentima <ldipentima@veritasgenetics.com>
Tue, 6 Aug 2019 13:08:54 +0000 (10:08 -0300)
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <ldipentima@veritasgenetics.com>

services/keep-web/handler.go
services/keep-web/handler_test.go
services/keep-web/server_test.go

index 083040b2197ca63ef90874d9dcd652f5ab740843..fab004c89f23fce759c8386b42f6db5d46023df1 100644 (file)
@@ -281,6 +281,7 @@ func (h *handler) ServeHTTP(wOrig http.ResponseWriter, r *http.Request) {
                        stripParts = 4
                        pathToken = true
                } else {
+                       log.Info("  !!!!  ATTN: Into /collections/uuid/path with anon token: ", h.Config.cluster.Users.AnonymousUserToken)
                        // /collections/ID/PATH...
                        collectionID = parseCollectionIDFromURL(pathParts[1])
                        tokens = []string{h.Config.cluster.Users.AnonymousUserToken}
index 3863265613f883b7c190584002b504f35fb43b44..17719601a9c7b76147b4abefea4edf7db3eff472 100644 (file)
@@ -594,12 +594,12 @@ func (s *IntegrationSuite) TestDirectoryListing(c *check.C) {
                        cutDirs: 1,
                },
                // This test case fails
-               // {
-               //      uri:     "download.example.com/collections/" + arvadostest.FooAndBarFilesInDirUUID + "/",
-               //      header:  authHeader,
-               //      expect:  []string{"dir1/foo", "dir1/bar"},
-               //      cutDirs: 2,
-               // },
+               {
+                       uri:     "download.example.com/collections/" + arvadostest.FooAndBarFilesInDirUUID + "/",
+                       header:  authHeader,
+                       expect:  []string{"dir1/foo", "dir1/bar"},
+                       cutDirs: 2,
+               },
                {
                        uri:     "download.example.com/users/active/foo_file_in_dir/",
                        header:  authHeader,
index 534ed9b3022d01e7d169fc5212ca1d973dae963f..b398f34065e2039941e17660a20d42497819203d 100644 (file)
@@ -501,6 +501,7 @@ func (s *IntegrationSuite) SetUpTest(c *check.C) {
        cfg.cluster.Services.WebDAV.InternalURLs[arvados.URL{Host: listen}] = arvados.ServiceInstance{}
        cfg.cluster.Services.WebDAVDownload.InternalURLs[arvados.URL{Host: listen}] = arvados.ServiceInstance{}
        cfg.cluster.ManagementToken = arvadostest.ManagementToken
+       cfg.cluster.Users.AnonymousUserToken = arvadostest.AnonymousToken
        s.testServer = &server{Config: cfg}
        err = s.testServer.Start()
        c.Assert(err, check.Equals, nil)