HDFS-16755. TestQJMWithFaults.testUnresolvableHostName() can fail due to unexpected host resolution (#4833)

Use ".invalid" domain from IETF RFC 2606 to ensure that the host doesn't resolve.

Contributed by Steve Vaughan Jr
This commit is contained in:
Steve Vaughan 2022-09-01 09:00:15 -04:00 committed by Steve Loughran
parent 6cc5c92a89
commit 3a6c8ff8bb
No known key found for this signature in database
GPG Key ID: D22CF846DBB162A0
1 changed files with 1 additions and 1 deletions

View File

@ -198,7 +198,7 @@ public void testRecoverAfterDoubleFailures() throws Exception {
public void testUnresolvableHostName() throws Exception {
expectedException.expect(UnknownHostException.class);
new QuorumJournalManager(conf,
new URI("qjournal://" + "bogus:12345" + "/" + JID), FAKE_NSINFO);
new URI("qjournal://" + "bogus.invalid:12345" + "/" + JID), FAKE_NSINFO);
}
/**