Added tests and cleanup.

Added tests for IPv6 getCountryV6. Also did some minor cleanup of
the code.