HTML is obviously likely to differ across browsers so this is less unexpected than the plaintext label test, but it would still be better to generate the `expected` value in such a way that you can reliably compare it to the `actual` value without doing a regex replace.

For example, you could generate `expected` by setting an element's contents and pulling the HTML out of it. That should ensure a reliable comparison with `actual` based on the actual behavior of the current browser rather than on assumptions baked into tests.