@Test public void testGoodLength() { String s = "hello"; assertTrue(DataValidation.validateLength(s, 4, 5)); assertTrue(DataValidation.validateLength(s, 5, 6)); assertTrue(DataValidation.validateLength(s, 5, 5)); assertTrue(DataValidation.validateLength(s, 4, 6)); }
public static boolean validateLength(String input, int minimum, int maximum) { return input.length() >= minimum && input.length() <= maximum; }
DataValidation { public static boolean validateLength(String input, int minimum, int maximum) { return input.length() >= minimum && input.length() <= maximum; } }
DataValidation { public static boolean validateLength(String input, int minimum, int maximum) { return input.length() >= minimum && input.length() <= maximum; }  }
DataValidation { public static boolean validateLength(String input, int minimum, int maximum) { return input.length() >= minimum && input.length() <= maximum; }  static boolean validateLength(String input, int minimum, int maximum); }
DataValidation { public static boolean validateLength(String input, int minimum, int maximum) { return input.length() >= minimum && input.length() <= maximum; }  static boolean validateLength(String input, int minimum, int maximum);  }