Bug fix in <td> wikitext escape handler + documented <th> handler

* This bug + bug fix in e33dc7ad were exposed by the removal of the
  quote context-sensitive handler in b5ba40b1

  More tests besides the one here coming in a later parser tests
  cleanup patch.

* Also documented the different behavior of the <th> wikitext handler
  where certain characters in text nodes need escaping no matter where
  in the DOM subtree it occurs.

* Updated/fixed <th> wikitext escaping parser tests to spec the special
  expectations for it.  Took the opportunity to update some older tests and
  document with html/php clauses that, in those cases where we don't
  emit <nowiki> tags, those tags are unnecessary.

* TODO:

  - Investigate fixing serializeChildren to push a dummy context-sensitive
    handler if nothing is passed in. This ensures that context-senstive
    handlers match up with the DOM tree level. This would be a cleaner fix,
    but requires investigating all users of seriazeChildren that currently
    don't pass in a context-sensitive handler.

  - Actually, because of the wikitext escaping requirements of the <th>
    node, the context-sensitive handler business is probably somewhat
    broken. To be more thoroughly looked into.

Change-Id: I224cbd0ba47963fceace0a6a95464bdc2b9ee57b
Merge "Bug fix in <td> wikitext escape handler + documented <th> handler"