Clean up minor items found during DiRT

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=151125802
This commit is contained in:
ctingue 2017-03-24 08:00:12 -07:00 committed by Ben McIlwain
parent 015d07a9b6
commit c6a1c3d870
2 changed files with 3 additions and 3 deletions

View file

@ -60,7 +60,7 @@ public final class DomainNameUtils {
public static String getTldFromDomainName(String fullyQualifiedDomainName) {
checkArgument(
!Strings.isNullOrEmpty(fullyQualifiedDomainName),
"secondLevelDomainName cannot be null or empty");
"fullyQualifiedDomainName cannot be null or empty");
return getTldFromDomainName(InternetDomainName.from(fullyQualifiedDomainName));
}
@ -74,7 +74,7 @@ public final class DomainNameUtils {
*/
public static String getTldFromDomainName(InternetDomainName domainName) {
checkArgumentNotNull(domainName);
checkArgument(domainName.hasParent(), "secondLevelDomainName does not have a TLD");
checkArgument(domainName.hasParent(), "domainName does not have a TLD");
return domainName.parent().toString();
}

View file

@ -45,7 +45,7 @@ public class DomainNameUtilsTest {
}
@Test
public void testCanonicalizeDomainName_acePrefixUnicodeChars() {
public void testCanonicalizeDomainName_acePrefixUnicodeChars() throws Exception {
thrown.expect(IllegalArgumentException.class);
canonicalizeDomainName("xn--みんな");
}