fix for string conversion of SimpleXMLElement in python 3 and 2
added test cases