File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed
main/java/ru/mystamps/web/validation
test/java/ru/mystamps/web/tests/cases Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -25,8 +25,8 @@ public final class ValidationRules {
25
25
public static final String LOGIN_REGEXP = "[-_a-zA-Z0-9]+" ;
26
26
27
27
public static final Integer NAME_MAX_LENGTH = 100 ;
28
- public static final String NAME_REGEXP1 = "[- \\ p{Alpha }]+" ;
29
- public static final String NAME_REGEXP2 = "[ \\ p{Alpha }]([- \\ p{Alpha }]+[ \\ p{Alpha }])*" ;
28
+ public static final String NAME_REGEXP1 = "[- \\ p{L }]+" ;
29
+ public static final String NAME_REGEXP2 = "[ \\ p{L }]([- \\ p{L }]+[ \\ p{L }])*" ;
30
30
31
31
public static final Integer PASSWORD_MIN_LENGTH = 4 ;
32
32
public static final String PASSWORD_REGEXP = "[-_a-zA-Z0-9]+" ;
Original file line number Diff line number Diff line change @@ -159,11 +159,10 @@ public void nameShouldNotBeTooLong() {
159
159
160
160
@ Test
161
161
public void nameWithAllowedCharactersShouldBeAccepted () {
162
- // TODO: test Russian letters (like 'Sемён Як-ушев')
163
-
164
162
final String [] names = new String [] {
165
163
"x" ,
166
- "Slava Se-mushin"
164
+ "Slava Se-mushin" ,
165
+ "Семён Якушев"
167
166
};
168
167
169
168
for (final String name : names ) {
You can’t perform that action at this time.
0 commit comments