s3api_test.go 557 B

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