Repository: web2py/web2py

Issue:
Change "upper case" and "lower case" to "uppercase" and "lowercase" in UI text
Uppercase and lowercase are the correct words, so now our grammatically correct custom text is different from the Web2Py validator messages.

In case you don't believe me. 😄 
- http://www.merriam-webster.com/dictionary/uppercase



Discussion:

Resolving patch:
diff --git a/applications/admin/languages/nl.py b/applications/admin/languages/nl.py
--- a/applications/admin/languages/nl.py
+++ b/applications/admin/languages/nl.py
@@ -352,9 +352,9 @@
 'modules': 'modules',
 'Multi User Mode': 'Multi User Mode',
 'Must include at least %s %s': 'Moet ten minste bevatten %s %s',
-'Must include at least %s lower case': 'Moet ten minste bevatten %s lower case',
+'Must include at least %s lowercase': 'Moet ten minste bevatten %s kleine letter',
 'Must include at least %s of the following : %s': 'Moet ten minste bevatten %s van het volgende : %s',
-'Must include at least %s upper case': 'Moet ten minste bevatten %s upper case',
+'Must include at least %s uppercase': 'Moet ten minste bevatten %s hoofdletter',
 'new application "%s" created': 'nieuwe applicatie "%s" gemaakt',
 'new application "%s" imported': 'new application "%s" imported',
 'New Application Wizard': 'Nieuwe Applicatie Wizard',
diff --git a/applications/admin/languages/uk.py b/applications/admin/languages/uk.py
--- a/applications/admin/languages/uk.py
+++ b/applications/admin/languages/uk.py
@@ -356,9 +356,9 @@
 'modules': 'модулі',
 'Multi User Mode': 'Multi User Mode',
 'Must include at least %s %s': 'Має вміщувати щонайменше %s %s',
-'Must include at least %s lower case': 'Повинен включати щонайменше %s малих букв',
+'Must include at least %s lowercase': 'Повинен включати щонайменше %s малих букв',
 'Must include at least %s of the following : %s': 'Має включати не менше %s таких символів : %s',
-'Must include at least %s upper case': 'Повинен включати щонайменше %s великих букв',
+'Must include at least %s uppercase': 'Повинен включати щонайменше %s великих букв',
 'new application "%s" created': 'новий додаток "%s" створено',
 'new application "%s" imported': 'new application "%s" imported',
 'New Application Wizard': 'Майстер створення нового додатку',
diff --git a/gluon/validators.py b/gluon/validators.py
--- a/gluon/validators.py
+++ b/gluon/validators.py
@@ -2470,7 +2470,7 @@ def __call__(self, value):
 
 class IS_LOWER(Validator):
     """
-    Converts to lower case::
+    Converts to lowercase::
 
         >>> IS_LOWER()('ABC')
         ('abc', None)
@@ -2485,7 +2485,7 @@ def __call__(self, value):
 
 class IS_UPPER(Validator):
     """
-    Converts to upper case::
+    Converts to uppercase::
 
         >>> IS_UPPER()('abc')
         ('ABC', None)
@@ -3025,22 +3025,22 @@ def __call__(self, value):
             all_upper = re.findall("[A-Z]", value)
             if self.upper > 0:
                 if not len(all_upper) >= self.upper:
-                    failures.append(translate("Must include at least %s upper case")
+                    failures.append(translate("Must include at least %s uppercase")
                                     % str(self.upper))
             else:
                 if len(all_upper) > 0:
                     failures.append(
-                        translate("May not include any upper case letters"))
+                        translate("May not include any uppercase letters"))
         if isinstance(self.lower, int):
             all_lower = re.findall("[a-z]", value)
             if self.lower > 0:
                 if not len(all_lower) >= self.lower:
-                    failures.append(translate("Must include at least %s lower case")
+                    failures.append(translate("Must include at least %s lowercase")
                                     % str(self.lower))
             else:
                 if len(all_lower) > 0:
                     failures.append(
-                        translate("May not include any lower case letters"))
+                        translate("May not include any lowercase letters"))
         if isinstance(self.number, int):
             all_number = re.findall("[0-9]", value)
             if self.number > 0:


Test patch:
diff --git a/gluon/tests/test_validators.py b/gluon/tests/test_validators.py
--- a/gluon/tests/test_validators.py
+++ b/gluon/tests/test_validators.py
@@ -843,7 +843,7 @@ def test_IS_STRONG(self):
                           '|'.join(['Minimum length is 8',
                                     'Maximum length is 4',
                                     'Must include at least 1 of the following: ~!@#$%^&*()_+-=?<>,.:;{}[]|',
-                                    'Must include at least 1 upper case',
+                                    'Must include at least 1 uppercase',
                                     'Must include at least 1 number']))
                          )
         rtn = IS_STRONG(es=True)('abcde')
@@ -851,7 +851,7 @@ def test_IS_STRONG(self):
                          ('abcde',
                           '|'.join(['Minimum length is 8',
                                     'Must include at least 1 of the following: ~!@#$%^&*()_+-=?<>,.:;{}[]|',
-                                    'Must include at least 1 upper case',
+                                    'Must include at least 1 uppercase',
                                     'Must include at least 1 number']))
                          )
         rtn = IS_STRONG(upper=0, lower=0, number=0, es=True)('Abcde1')
@@ -859,8 +859,8 @@ def test_IS_STRONG(self):
                          ('Abcde1',
                           '|'.join(['Minimum length is 8',
                                     'Must include at least 1 of the following: ~!@#$%^&*()_+-=?<>,.:;{}[]|',
-                                    'May not include any upper case letters',
-                                    'May not include any lower case letters',
+                                    'May not include any uppercase letters',
+                                    'May not include any lowercase letters',
                                     'May not include any numbers']))
                          )