Make names helper more resilient… and actually test it