Avoid printing in S3 tests (#7043)

This commit is contained in:
Harshavardhana 2019-01-07 22:32:30 +05:30 committed by Nitish Tiwari
parent 5a80cbec2a
commit 7f2d439baa

View File

@ -63,12 +63,16 @@ func TestReadGWMetadata(t *testing.T) {
for i, tt := range tests {
buf := bytes.NewBufferString(tt.metaStr)
m, err := readGWMetadata(context.Background(), *buf)
t.Log(m)
if err != nil && tt.pass {
t.Errorf("Test %d: Expected parse gw metadata to succeed, but failed", i)
}
if err == nil && !tt.pass {
t.Errorf("Test %d: Expected parse gw metadata to succeed, but failed", i)
}
if err == nil {
if m.Version != gwMetaVersion {
t.Errorf("Test %d: Expected version %s, but failed with %s", i, gwMetaVersion, m.Version)
}
}
}
}