mirror of
https://github.com/ceph/s3-tests.git
synced 2025-05-13 05:18:16 +00:00
website: Improve XML handling and x-amz-website-redirect-location tests
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
This commit is contained in:
parent
e0655234b1
commit
88b6328003
2 changed files with 76 additions and 24 deletions
|
@ -257,6 +257,10 @@ def with_setup_kwargs(setup, teardown=None):
|
|||
# yield _test_gen, '1'
|
||||
# yield _test_gen
|
||||
|
||||
def trim_xml(xml_str):
|
||||
p = etree.XMLParser(remove_blank_text=True)
|
||||
elem = etree.XML(xml_str, parser=p)
|
||||
return etree.tostring(elem)
|
||||
|
||||
def normalize_xml(xml, pretty_print=True):
|
||||
if xml is None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue