You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
626 B

4 years ago
4 years ago
  1. package s3api
  2. import (
  3. "github.com/seaweedfs/seaweedfs/weed/s3api/s3err"
  4. "testing"
  5. "time"
  6. )
  7. func TestCopyObjectResponse(t *testing.T) {
  8. // https://docs.aws.amazon.com/AmazonS3/latest/API/API_CopyObject.html
  9. response := CopyObjectResult{
  10. ETag: "12345678",
  11. LastModified: time.Now(),
  12. }
  13. println(string(s3err.EncodeXMLResponse(response)))
  14. }
  15. func TestCopyPartResponse(t *testing.T) {
  16. // https://docs.aws.amazon.com/AmazonS3/latest/API/API_UploadPartCopy.html
  17. response := CopyPartResult{
  18. ETag: "12345678",
  19. LastModified: time.Now(),
  20. }
  21. println(string(s3err.EncodeXMLResponse(response)))
  22. }