YARN-9774. Fix order of arguments for assertEquals in TestSLSUtils. Contributed by Nikhil Navadiya.

(cherry picked from commit 84b1982060)
This commit is contained in:
Akira Ajisaka 2019-08-23 14:38:50 +09:00
parent 900384cf57
commit 42c6119e47
No known key found for this signature in database
GPG Key ID: C1EDBB9CA400FD50
1 changed files with 4 additions and 4 deletions

View File

@ -30,13 +30,13 @@ public class TestSLSUtils {
public void testGetRackHostname() { public void testGetRackHostname() {
String str = "/rack1/node1"; String str = "/rack1/node1";
String rackHostname[] = SLSUtils.getRackHostName(str); String rackHostname[] = SLSUtils.getRackHostName(str);
Assert.assertEquals(rackHostname[0], "rack1"); Assert.assertEquals("rack1", rackHostname[0]);
Assert.assertEquals(rackHostname[1], "node1"); Assert.assertEquals("node1", rackHostname[1]);
str = "/rackA/rackB/node1"; str = "/rackA/rackB/node1";
rackHostname = SLSUtils.getRackHostName(str); rackHostname = SLSUtils.getRackHostName(str);
Assert.assertEquals(rackHostname[0], "rackA/rackB"); Assert.assertEquals("rackA/rackB", rackHostname[0]);
Assert.assertEquals(rackHostname[1], "node1"); Assert.assertEquals("node1", rackHostname[1]);
} }
@Test @Test