Add tests for XML

http://www.pivotaltracker.com/story/show/61096426