@classmethod
def heading_with_text(cls, level, text):
    """Returns an XPath to find an HTML <h> of level `level` containing the text in `text`."""
    return cls('//h%s[node()="%s"]' % (level, text))
