mirror of
https://github.com/Findus23/acronomy.git
synced 2024-09-19 15:33:45 +02:00
add test for uppercase first letter
This commit is contained in:
parent
ad2687db46
commit
9eb19c79bd
1 changed files with 11 additions and 0 deletions
|
@ -38,3 +38,14 @@ class LetterCheck(BaseCheck):
|
|||
|
||||
|
||||
registry.register(LetterCheck)
|
||||
|
||||
|
||||
class FullNameCheck(BaseCheck):
|
||||
def run(self):
|
||||
for acronym in Acronym.objects.all():
|
||||
first_letter = acronym.full_name[0]
|
||||
if first_letter.islower():
|
||||
yield CheckInfo(f"first letter of full name should be uppercase ({acronym.full_name})")
|
||||
|
||||
|
||||
registry.register(FullNameCheck)
|
||||
|
|
Loading…
Reference in a new issue