@Test public void test_invalid_should_return_false_when_all_fields_are_within_length_limit() { final Address address = Address.builder() .address(multiplyCharacter(300, "A")) .city(multiplyCharacter(300, "B")) .pinCode(multiplyCharacter(10, "A")) .build(); assertFalse(address.isInvalid()); }
boolean isInvalid() { return isPinCodeInvalid() || isCityInvalid() || isAddressInvalid(); }
Address { boolean isInvalid() { return isPinCodeInvalid() || isCityInvalid() || isAddressInvalid(); } }
Address { boolean isInvalid() { return isPinCodeInvalid() || isCityInvalid() || isAddressInvalid(); }  }
Address { boolean isInvalid() { return isPinCodeInvalid() || isCityInvalid() || isAddressInvalid(); }   }
Address { boolean isInvalid() { return isPinCodeInvalid() || isCityInvalid() || isAddressInvalid(); }    }