Fix unit test regex for non-trivial hostnames.