Advertisement
Guest User

Untitled

a guest
Nov 22nd, 2011
38
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.68 KB | None | 0 0
  1. index 788a837..07e131d 100644
  2. --- a/s3tests/functional/test_headers.py
  3. +++ b/s3tests/functional/test_headers.py
  4. @@ -544,7 +544,13 @@ def test_bucket_create_bad_expect_unreadable():
  5. @attr('fails_on_rgw')
  6. def test_bucket_create_bad_contentlength_empty():
  7. _add_custom_headers({'Content-Length': ''})
  8. - e = assert_raises(boto.exception.S3ResponseError, get_new_bucket)
  9. + try:
  10. + e = assert_raises(boto.exception.S3ResponseError, get_new_bucket)
  11. + except AssertionError as ae:
  12. + # this test may leave the connection in bad state
  13. + s3.main.close()
  14. + raise ae
  15. +
  16. eq(e.status, 400)
  17. eq(e.reason, 'Bad Request')
  18. eq(e.error_code, None)
  19.  
  20.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement