mirror of
https://github.com/minio/minio.git
synced 2025-11-21 10:16:03 -05:00
API: add writePartTooSmallErrorResponse to extend standard error responses. (#2005)
This function is added to extend the standard error responses. Which is needed in some cases for example CompleteMultipartUpload should respond with ErrPartTooSmall error when parts uploaded are lesser than 5MB (i.e minimum allowed size per part). Fixes #1536
This commit is contained in:
@@ -1841,7 +1841,7 @@ func testObjectCompleteMultipartUpload(obj ObjectLayer, instanceType string, t *
|
||||
// Test case with non existent object name (Test number 14).
|
||||
{bucketNames[0], "my-object", uploadIDs[0], []completePart{{ETag: "abcd", PartNumber: 1}}, "", InvalidUploadID{UploadID: uploadIDs[0]}, false},
|
||||
// Testing for Part being too small (Test number 15).
|
||||
{bucketNames[0], objectNames[0], uploadIDs[0], inputParts[1].parts, "", PartTooSmall{}, false},
|
||||
{bucketNames[0], objectNames[0], uploadIDs[0], inputParts[1].parts, "", PartTooSmall{PartNumber: 1}, false},
|
||||
// TestCase with invalid Part Number (Test number 16).
|
||||
// Should error with Invalid Part .
|
||||
{bucketNames[0], objectNames[0], uploadIDs[0], inputParts[2].parts, "", InvalidPart{}, false},
|
||||
|
||||
Reference in New Issue
Block a user