Skip to content

Commit

Permalink
fix style
Browse files Browse the repository at this point in the history
  • Loading branch information
tarikozyurtt committed Jul 11, 2024
1 parent df52429 commit aa9ca7f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 13 deletions.
5 changes: 2 additions & 3 deletions command/sync.go
Original file line number Diff line number Diff line change
Expand Up @@ -261,9 +261,8 @@ func compareObjects(sourceObjects, destObjects chan *storage.Object, isSrcBatch

for {
if srcOk {
if isSrcBatch {
srcName = filepath.ToSlash(src.URL.Relative())
} else {
srcName = filepath.ToSlash(src.URL.Relative())
if !isSrcBatch {
srcName = src.URL.Base()
}
}
Expand Down
20 changes: 10 additions & 10 deletions e2e/sync_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func TestSyncSingleS3ObjectToLocalTwice(t *testing.T) {
}

// sync s3://bucket/dir/source.go .
func TestSyncSingleS3ObjectFromDirToLocal(t *testing.T) {
func TestSyncSinglePrefixedS3ObjectToCurrentDirectory(t *testing.T) {
t.Parallel()

s3client, s5cmd := setup(t)
Expand Down Expand Up @@ -122,8 +122,8 @@ func TestSyncSingleS3ObjectFromDirToLocal(t *testing.T) {
assertLines(t, result.Stdout(), map[int]compareFunc{})
}

// sync s3://bucket/dir/source.go folder/
func TestSyncSingleS3ObjectFromDirToLocalDir(t *testing.T) {
// sync s3://bucket/prefix/source.go dir/
func TestSyncPrefixedSingleS3ObjectToLocalDirectory(t *testing.T) {
t.Parallel()

s3client, s5cmd := setup(t)
Expand Down Expand Up @@ -154,8 +154,8 @@ func TestSyncSingleS3ObjectFromDirToLocalDir(t *testing.T) {
assertLines(t, result.Stdout(), map[int]compareFunc{})
}

// sync s3://bucket/source.go folder/
func TestSyncSingleS3ObjectToLocalDir(t *testing.T) {
// sync s3://bucket/source.go dir/
func TestSyncSingleS3ObjectToLocalDirectory(t *testing.T) {
t.Parallel()

s3client, s5cmd := setup(t)
Expand Down Expand Up @@ -221,8 +221,8 @@ func TestSyncLocalFileToS3Twice(t *testing.T) {
assertLines(t, result.Stdout(), map[int]compareFunc{})
}

// sync file s3://bucket/dir/
func TestSyncLocalFileToS3Dir(t *testing.T) {
// sync file s3://bucket/prefix/
func TestSyncLocalFileToS3Prefix(t *testing.T) {
t.Parallel()

s3client, s5cmd := setup(t)
Expand Down Expand Up @@ -258,7 +258,7 @@ func TestSyncLocalFileToS3Dir(t *testing.T) {
}

// sync dir/file s3://bucket
func TestSyncLocalDirFileToS3(t *testing.T) {
func TestSyncLocalFileInDirectoryToS3(t *testing.T) {
t.Parallel()

s3client, s5cmd := setup(t)
Expand Down Expand Up @@ -294,8 +294,8 @@ func TestSyncLocalDirFileToS3(t *testing.T) {
assertLines(t, result.Stdout(), map[int]compareFunc{})
}

// sync dir/file s3://bucket/dir/
func TestSyncLocalDirFileToS3Dir(t *testing.T) {
// sync dir/file s3://bucket/prefix/
func TestSyncLocalFileInDirectoryToS3Prefix(t *testing.T) {
t.Parallel()

s3client, s5cmd := setup(t)
Expand Down

0 comments on commit aa9ca7f

Please sign in to comment.