Adds test to the Dialer

Minor clean up as well