mirror of
https://github.com/pgsty/minio.git
synced 2026-08-09 07:43:29 +03:00
committed by
Krishna Srinivas
parent
ce7c9c651d
commit
bc73a1a1cb
@@ -17,6 +17,7 @@
|
||||
package cmd
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"reflect"
|
||||
"testing"
|
||||
|
||||
@@ -144,10 +145,13 @@ func TestGCSMultipartMetaName(t *testing.T) {
|
||||
|
||||
// Test for gcsMultipartDataName.
|
||||
func TestGCSMultipartDataName(t *testing.T) {
|
||||
uploadID := "a"
|
||||
etag := "b"
|
||||
expected := pathJoin(gcsMinioMultipartPathV1, uploadID, etag)
|
||||
got := gcsMultipartDataName(uploadID, etag)
|
||||
var (
|
||||
uploadID = "a"
|
||||
etag = "b"
|
||||
partNumber = 1
|
||||
)
|
||||
expected := pathJoin(gcsMinioMultipartPathV1, uploadID, fmt.Sprintf("%05d.%s", partNumber, etag))
|
||||
got := gcsMultipartDataName(uploadID, partNumber, etag)
|
||||
if expected != got {
|
||||
t.Errorf("expected: %s, got: %s", expected, got)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user