Skip to content

Commit 4431c3e

Browse files
committed
Exluded another locale from author name generation during testing, due to problematic romanization.
- Legacy-Id: 14519
1 parent c1f8b1b commit 4431c3e

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

ietf/person/factories.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,12 @@
1919
fake = faker.Factory.create()
2020

2121
def random_faker():
22-
# The transliteration of arabic names introduces non-alphabetic
23-
# characgters that don't work with the draft author extraction code, and
24-
# also don't seem to match the way people with arabic names romanize them.
25-
locales = set( [ l for l in faker.config.AVAILABLE_LOCALES if not l.startswith('ar_') ] )
22+
# The transliteration of some arabic and devanagari names introduces
23+
# non-alphabetic characgters that don't work with the draft author
24+
# extraction code, and also don't seem to match the way people with arabic
25+
# names romanize arabic names. Exlude those locales from name generation
26+
# in order to avoid test failures.
27+
locales = set( [ l for l in faker.config.AVAILABLE_LOCALES if not (l.startswith('ar_') or l.startswith('sg_') ] )
2628
return faker.Faker(random.sample(locales, 1)[0])
2729

2830
class UserFactory(factory.DjangoModelFactory):

0 commit comments

Comments
 (0)