mirror of
https://github.com/haveno-dex/haveno.git
synced 2024-10-01 01:35:48 -04:00
increase max question length for InteracETransfer to 160 characters #969
This commit is contained in:
parent
cf1fabd0bb
commit
0919d92ce4
@ -13,7 +13,7 @@ public class InteracETransferQuestionValidator extends InputValidator {
|
||||
public InteracETransferQuestionValidator(LengthValidator lengthValidator, RegexValidator regexValidator) {
|
||||
|
||||
lengthValidator.setMinLength(1);
|
||||
lengthValidator.setMaxLength(40);
|
||||
lengthValidator.setMaxLength(160);
|
||||
this.lengthValidator = lengthValidator;
|
||||
|
||||
regexValidator.setPattern("[A-Za-z0-9\\-\\_\\'\\,\\.\\? ]+");
|
||||
|
@ -53,7 +53,7 @@ public class InteracETransferQuestionValidatorTest {
|
||||
|
||||
assertFalse(validator.validate(null).isValid); // null
|
||||
assertFalse(validator.validate("").isValid); // empty
|
||||
assertFalse(validator.validate("abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ").isValid); // too long
|
||||
assertFalse(validator.validate("abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ").isValid); // too long
|
||||
assertFalse(validator.validate("abc !@#").isValid); // invalid characters
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user