Strip empty tr/li nodes from template/extension content

* Empty nodes from top-level content is left untouched.

* If there are additional nodes we want to strip,
  we can add them later, but list and table rows seem to be
  the most common ones during RT and rendering tests.

* Added parser tests. One of these fails html2wt (and hence
  html2html) modes because our serializer does't discards
  new empty tr-rows it appears.

* Verified that http://localhost:8000/itwiki/Luna has the
  empty rows stripped in its infobox.

Change-Id: I5c82c879240ef5a52e99c572bdab7fc2298545db