mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 12:10:24 +03:00
Remove error package and cause functions (#5784)
This commit is contained in:
@@ -25,7 +25,6 @@ import (
|
||||
"testing"
|
||||
|
||||
humanize "github.com/dustin/go-humanize"
|
||||
"github.com/minio/minio/pkg/errors"
|
||||
"github.com/minio/minio/pkg/hash"
|
||||
)
|
||||
|
||||
@@ -124,7 +123,7 @@ func testObjectAbortMultipartUpload(obj ObjectLayer, instanceType string, t Test
|
||||
if testCase.expectedErrType == nil && err != nil {
|
||||
t.Errorf("Test %d, unexpected err is received: %v, expected:%v\n", i+1, err, testCase.expectedErrType)
|
||||
}
|
||||
if testCase.expectedErrType != nil && !isSameType(errors.Cause(err), testCase.expectedErrType) {
|
||||
if testCase.expectedErrType != nil && !isSameType(err, testCase.expectedErrType) {
|
||||
t.Errorf("Test %d, unexpected err is received: %v, expected:%v\n", i+1, err, testCase.expectedErrType)
|
||||
}
|
||||
}
|
||||
@@ -153,7 +152,6 @@ func testObjectAPIIsUploadIDExists(obj ObjectLayer, instanceType string, t TestE
|
||||
}
|
||||
|
||||
err = obj.AbortMultipartUpload(context.Background(), bucket, object, "abc")
|
||||
err = errors.Cause(err)
|
||||
switch err.(type) {
|
||||
case InvalidUploadID:
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user