Add unit test and minor fixes to AddressUtilities.