diff --git a/oss/bucket_test.go b/oss/bucket_test.go index 1f2748b9..85035eba 100644 --- a/oss/bucket_test.go +++ b/oss/bucket_test.go @@ -739,7 +739,7 @@ func (s *OssBucketSuite) TestPutObjectNegative(c *C) { err = s.bucket.PutObjectFromFile(objectName, "bucket.go", IfModifiedSince(pastDate)) c.Assert(err, NotNil) - err = s.bucket.PutObjectFromFile(objectName, "/tmp/xxx") + err = s.bucket.PutObjectFromFile(objectName, "../tmp/xxx") c.Assert(err, NotNil) } @@ -907,7 +907,7 @@ func (s *OssBucketSuite) TestGetObjectToWriterNegative(c *C) { c.Assert(err, IsNil) // Not exist - err = s.bucket.GetObjectToFile(objectName, "/root/123abc9874") + err = s.bucket.GetObjectToFile(objectName, "../root/123abc9874") c.Assert(err, NotNil) // Invalid option diff --git a/oss/download_test.go b/oss/download_test.go index b7c0b609..28c27820 100644 --- a/oss/download_test.go +++ b/oss/download_test.go @@ -365,10 +365,10 @@ func (s *OssDownloadSuite) TestDownloadNegative(c *C) { c.Assert(err, IsNil) // Local file does not exist - err = s.bucket.DownloadFile(objectName, "/tmp/", 100*1024) + err = s.bucket.DownloadFile(objectName, "../tmp/", 100*1024) c.Assert(err, NotNil) - err = s.bucket.DownloadFile(objectName, "/tmp/", 100*1024, Routines(2)) + err = s.bucket.DownloadFile(objectName, "../tmp/", 100*1024, Routines(2)) c.Assert(err, NotNil) // Invalid part size diff --git a/oss/multipart_test.go b/oss/multipart_test.go index 8fc99cd3..77044717 100644 --- a/oss/multipart_test.go +++ b/oss/multipart_test.go @@ -968,7 +968,7 @@ func (s *OssBucketMultipartSuite) TestDownloadFileNegative(c *C) { c.Assert(err, NotNil) // File does not exist - err = s.bucket.DownloadFile(objectName, "/OSS/TEMP/ZIBI/QUQU/BALA", 1024*1024*1024+1) + err = s.bucket.DownloadFile(objectName, "../TEMP/ZIBI/QUQU/BALA", 1024*1024*1024+1) c.Assert(err, NotNil) // Key does not exist