From 5c6fdc710f8680701720c98e7ebdcd4ab589f703 Mon Sep 17 00:00:00 2001 From: Arthur Baars Date: Wed, 6 Jan 2016 18:17:17 +0000 Subject: [PATCH] GCS Storagedriver: fix test failure caused by #1187 Signed-off-by: Arthur Baars --- docs/storage/driver/gcs/gcs.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/storage/driver/gcs/gcs.go b/docs/storage/driver/gcs/gcs.go index 4cef972cb..2b190dec5 100644 --- a/docs/storage/driver/gcs/gcs.go +++ b/docs/storage/driver/gcs/gcs.go @@ -461,6 +461,11 @@ func (d *driver) List(context ctx.Context, path string) ([]string, error) { break } } + if path != "/" && len(list) == 0 { + // Treat empty response as missing directory, since we don't actually + // have directories in Google Cloud Storage. + return nil, storagedriver.PathNotFoundError{Path: path} + } return list, nil }