Changes between Initial Version and Version 1 of Ticket #31570, comment 15


Ignore:
Timestamp:
May 15, 2020, 9:43:01 AM (4 years ago)
Author:
Shai Berger

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #31570, comment 15

    initial v1  
    1515
    1616As an aside, this was the major missing piece which allowed me to reproduce exactly the behavior I saw in production: Adding the explicit plural forms to my apps' translation files, and making the test run two rounds of translations (as only when the first round ends, all languages are loaded), that is
    17 {{{#!diff
    18 *** trans/tests.py~     2020-05-13 12:38:30.028586931 +0300
    19 --- trans/tests.py      2020-05-15 16:32:14.537889998 +0300
    20 *************** class TestTranslations(SimpleTestCase):
    21 *** 10,17 ****
     17{{{#!diff trans/tests.py
     18diff trans/tests.py~
     19--- trans/tests.py~     2020-05-13 12:38:30.028586931 +0300
     20+++ trans/tests.py      2020-05-15 16:32:14.537889998 +0300
     21@@ -10,8 +10,9 @@ class TestTranslations(SimpleTestCase):
    2222              'en_CA': 'canuck',
    2323              'en': 'local country person',
    2424          }
    25 !         for language, nick in country_people_nicknames.items():
    26 !             with self.subTest(language=language):
    27                   activate(language)
    28                   self.assertEqual(_('local country person'), nick)
    29  
    30 --- 10,18 ----
    31               'en_CA': 'canuck',
    32               'en': 'local country person',
    33           }
    34 !         for rnd in "12":
    35 !          for language, nick in country_people_nicknames.items():
    36 !             with self.subTest(language=language, round=rnd):
     25-         for language, nick in country_people_nicknames.items():
     26-             with self.subTest(language=language):
     27+         for rnd in "12":
     28+          for language, nick in country_people_nicknames.items():
     29+             with self.subTest(language=language, round=rnd):
    3730                  activate(language)
    3831                  self.assertEqual(_('local country person'), nick)
Back to Top