diff options
author | fritzy <fritzy@ip-10-251-242-239.ec2.internal> | 2010-09-02 20:01:28 +0000 |
---|---|---|
committer | fritzy <fritzy@ip-10-251-242-239.ec2.internal> | 2010-09-02 20:01:28 +0000 |
commit | d576e32f7aa28332848cdd6e39893266eded64fd (patch) | |
tree | e36a1b85dc0692b6be223f2259c3c2df9cdb5e53 /tests/sleektest.py | |
parent | 6dfea828be54d9048779d06b4b31be98b58a2343 (diff) | |
parent | 4a2e7c5393da945359edc2648a2ec124481acf7d (diff) | |
download | slixmpp-d576e32f7aa28332848cdd6e39893266eded64fd.tar.gz slixmpp-d576e32f7aa28332848cdd6e39893266eded64fd.tar.bz2 slixmpp-d576e32f7aa28332848cdd6e39893266eded64fd.tar.xz slixmpp-d576e32f7aa28332848cdd6e39893266eded64fd.zip |
Merge branch 'develop' of git@github.com:fritzy/SleekXMPP into develop
Diffstat (limited to 'tests/sleektest.py')
-rw-r--r-- | tests/sleektest.py | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/tests/sleektest.py b/tests/sleektest.py index 801253d3..66535bcb 100644 --- a/tests/sleektest.py +++ b/tests/sleektest.py @@ -504,7 +504,18 @@ class SleekTest(unittest.TestCase): if xml.attrib != other.attrib: return False - # Step 3: Recursively check children + # Step 3: Check text + if xml.text is None: + xml.text = "" + if other.text is None: + other.text = "" + xml.text = xml.text.strip() + other.text = other.text.strip() + + if xml.text != other.text: + return False + + # Step 4: Recursively check children for child in xml: child2s = other.findall("%s" % child.tag) if child2s is None: |