// - authenticated /index/prefix request | superuser
//
// The only /index requests that should succeed are those issued by the
// - authenticated /index/prefix request | superuser
//
// The only /index requests that should succeed are those issued by the
//
func (s *HandlerSuite) TestIndexHandler(c *check.C) {
c.Assert(s.handler.setup(context.Background(), s.cluster, "", prometheus.NewRegistry(), testServiceURL), check.IsNil)
//
func (s *HandlerSuite) TestIndexHandler(c *check.C) {
c.Assert(s.handler.setup(context.Background(), s.cluster, "", prometheus.NewRegistry(), testServiceURL), check.IsNil)
vols := s.handler.volmgr.AllWritable()
vols[0].Put(context.Background(), TestHash, TestBlock)
vols := s.handler.volmgr.AllWritable()
vols[0].Put(context.Background(), TestHash, TestBlock)
// tests, to ensure the MockVolume deletes the blocks
// even though they have just been created.
s.cluster.Collections.BlobSigningTTL = arvados.Duration(0)
// tests, to ensure the MockVolume deletes the blocks
// even though they have just been created.
s.cluster.Collections.BlobSigningTTL = arvados.Duration(0)
// should return success but leave the block on the volume.
vols[0].Put(context.Background(), TestHash, TestBlock)
s.cluster.Collections.BlobSigningTTL = arvados.Duration(time.Hour)
// should return success but leave the block on the volume.
vols[0].Put(context.Background(), TestHash, TestBlock)
s.cluster.Collections.BlobSigningTTL = arvados.Duration(time.Hour)
// Unauthenticated request, no server key
// => OK (unsigned response)
unsignedLocator := "/" + TestHash
// Unauthenticated request, no server key
// => OK (unsigned response)
unsignedLocator := "/" + TestHash
// Unauthenticated request, unsigned locator
// => OK
unsignedLocator := "/" + TestHash
// Unauthenticated request, unsigned locator
// => OK
unsignedLocator := "/" + TestHash