Package org.apache.tajo.master.cluster

Examples of org.apache.tajo.master.cluster.ServerName.compareTo()


  public void testCompareTo() {
    ServerName s1 = new ServerName("ex1.com:50030");
    ServerName s2 = new ServerName("ex1.com:60030");
   
    assertTrue(s1.compareTo(s2) < 0);
    assertTrue(s2.compareTo(s1) > 0);
   
    ServerName s3 = new ServerName("ex1.com:50030");
    assertTrue(s1.compareTo(s3) == 0);
   
    ServerName s4 = new ServerName("ex2.com:50030");
View Full Code Here


    ServerName s3 = new ServerName("ex1.com:50030");
    assertTrue(s1.compareTo(s3) == 0);
   
    ServerName s4 = new ServerName("ex2.com:50030");
    assertTrue(s1.compareTo(s4) < 0);
    assertTrue(s4.compareTo(s1) > 0);
  }

  @Test (expected = IllegalArgumentException.class)
  public void testException() {
    new ServerName("ex1.com");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.