Ezio Melotti <[email protected]> added the comment: Here is a new patch based on Dan's last patch. Correct me if I'm wrong, but it seems to me that it's not possible for a node to have only text-nodes as children and yet have more than one child; i.e. you can't have two or more adjacent text nodes, because they would be considered as a single text node. I therefore changed the check with all() to check if there's only a child and if it's a text node. I also added a test that checks where the \n and \t are added, because testing only that the DOM is preserved is not enough.
---------- stage: test needed -> commit review Added file: http://bugs.python.org/file23692/issue4147.diff _______________________________________ Python tracker <[email protected]> <http://bugs.python.org/issue4147> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
