Skip to content

Commit

Permalink
gofmt
Browse files Browse the repository at this point in the history
  • Loading branch information
yuuki committed Dec 25, 2015
1 parent c0be88f commit 6a9bfe2
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 9 deletions.
10 changes: 5 additions & 5 deletions aws/s3.go
Expand Up @@ -19,8 +19,8 @@ const uploadPartSize = 64 * 1024 * 1024 // 64MB part size
const downloadPartSize = uploadPartSize

type S3Client struct {
svc s3iface.S3API
uploader s3uploader
svc s3iface.S3API
uploader s3uploader
downloader s3downloader
}

Expand All @@ -32,8 +32,8 @@ func NewS3Client() *S3Client {
svc = s3.New(session.New())
}
return &S3Client{
svc: svc,
uploader: newS3Uploader(svc),
svc: svc,
uploader: newS3Uploader(svc),
downloader: newS3Downloader(svc),
}
}
Expand All @@ -48,7 +48,7 @@ func (clt *S3Client) ExistsBucket(bucket string) (bool, error) {
return true, nil
}

func (clt *S3Client) Upload(bucket, key string , reader io.Reader) (string, error) {
func (clt *S3Client) Upload(bucket, key string, reader io.Reader) (string, error) {
ok, err := clt.ExistsBucket(bucket)
if err != nil {
return "", err
Expand Down
4 changes: 2 additions & 2 deletions aws/s3_test.go
Expand Up @@ -38,8 +38,8 @@ func TestUpload(t *testing.T) {

mockUploader.On("Upload", &s3manager.UploadInput{
Bucket: aws.String("droot-containers"),
Key: aws.String("app.tar.gz"),
Body: in,
Key: aws.String("app.tar.gz"),
Body: in,
}, mock.AnythingOfType("func(*s3manager.Uploader)"),
).Return(&s3manager.UploadOutput{
Location: "https://droot-containers.s3-ap-northeast-1.amazonaws.com/app.tar.gz",
Expand Down
1 change: 0 additions & 1 deletion aws/s3manageriface.go
Expand Up @@ -24,7 +24,6 @@ func (c *_s3uploader) Upload(input *s3manager.UploadInput, option func(*s3manage
return c.uploader.Upload(input, option)
}


type s3downloader interface {
Download(io.WriterAt, *s3.GetObjectInput, ...func(*s3manager.Downloader)) (int64, error)
}
Expand Down
1 change: 0 additions & 1 deletion log/log.go
Expand Up @@ -37,4 +37,3 @@ func Error(v ...interface{}) {
func Errorf(format string, v ...interface{}) {
log.Fatalf(format, v...)
}

0 comments on commit 6a9bfe2

Please sign in to comment.