added unit tests for email expansion