diff options
| author | zorun <github@bitsofnetworks.org> | 2020-04-25 11:55:20 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-04-25 11:55:20 +0200 |
| commit | d6d084f26a9de543527486e3c1fbc4e9100fddbd (patch) | |
| tree | 3546f4c5043d22ae984a05e6a07e919944514c1f /ihatemoney/tests/tests.py | |
| parent | c2afed269a2f0785852f5ffd0ae9ac840b56927c (diff) | |
| download | ihatemoney-mirror-d6d084f26a9de543527486e3c1fbc4e9100fddbd.zip ihatemoney-mirror-d6d084f26a9de543527486e3c1fbc4e9100fddbd.tar.gz ihatemoney-mirror-d6d084f26a9de543527486e3c1fbc4e9100fddbd.tar.bz2 | |
Fix translations (#575)
* Fix user-facing string and update translation catalog
In the flash message confirming member creation, change "member had been
added" into the correct form "member has been added".
No translation has been changed. Some translators seem to have already
spotted the mistake while translating, but I can't tell for all languages.
* Change "Person" to "Participant" in history view
Currently, the main user-facing term is "Participant", as seen for
instance in the "Add participant" form. "Person" is not used anywhere in
the interface.
See #302 for a more general discussion on choosing the right terminology.
* Fix obsolete translations.
Co-authored-by: Baptiste Jonglez <git@bitsofnetworks.org>
Co-authored-by: Rémy HUBSCHER <hubscher.remy@gmail.com>
Diffstat (limited to 'ihatemoney/tests/tests.py')
| -rw-r--r-- | ihatemoney/tests/tests.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/ihatemoney/tests/tests.py b/ihatemoney/tests/tests.py index c836c97..b50fae6 100644 --- a/ihatemoney/tests/tests.py +++ b/ihatemoney/tests/tests.py @@ -2123,7 +2123,7 @@ class APITestCase(IhatemoneyTestCase): resp = self.client.get("/raclette/history", follow_redirects=True) self.assertEqual(resp.status_code, 200) self.assertIn( - f"Person {em_surround('alexis')} added", resp.data.decode("utf-8") + f"Participant {em_surround('alexis')} added", resp.data.decode("utf-8") ) self.assertIn( f"Project {em_surround('raclette')} added", resp.data.decode("utf-8"), @@ -2578,7 +2578,7 @@ class HistoryTestCase(IhatemoneyTestCase): resp = self.client.get("/demo/history") self.assertEqual(resp.status_code, 200) self.assertIn( - f"Person {em_surround('alexis')} added", resp.data.decode("utf-8") + f"Participant {em_surround('alexis')} added", resp.data.decode("utf-8") ) # create a bill @@ -2666,7 +2666,7 @@ class HistoryTestCase(IhatemoneyTestCase): self.assertEqual(resp.status_code, 200) self.assertRegex( resp.data.decode("utf-8"), - r"Person %s:\s* Weight changed\s* from %s\s* to %s" + r"Participant %s:\s* Weight changed\s* from %s\s* to %s" % ( em_surround("alexis", regex_escape=True), em_surround("1.0", regex_escape=True), @@ -2674,12 +2674,14 @@ class HistoryTestCase(IhatemoneyTestCase): ), ) self.assertIn( - "Person %s renamed to %s" + "Participant %s renamed to %s" % (em_surround("alexis"), em_surround("new name"),), resp.data.decode("utf-8"), ) self.assertLess( - resp.data.decode("utf-8").index(f"Person {em_surround('alexis')} renamed"), + resp.data.decode("utf-8").index( + f"Participant {em_surround('alexis')} renamed" + ), resp.data.decode("utf-8").index("Weight changed"), ) @@ -2690,7 +2692,7 @@ class HistoryTestCase(IhatemoneyTestCase): resp = self.client.get("/demo/history") self.assertEqual(resp.status_code, 200) self.assertIn( - f"Person {em_surround('new name')} removed", resp.data.decode("utf-8") + f"Participant {em_surround('new name')} removed", resp.data.decode("utf-8") ) def test_double_bill_double_person_edit_second(self): |
