Fix TextHelper::autoLinkEmail() near HTML

Fix up autoLinkEmail() near HTML, and restructure the test cases to use a provider which I think makes the tests easier to read/modify/run. Linking email addresses near HTML tags and HTML entities should work now.

Fixes #3656