blob: 488dac1dedc60f1dff434bab740fe3f8bb51351a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
diff --git a/oslo_i18n/tests/test_message.py b/oslo_i18n/tests/test_message.py
index 85dbd67..16492bb 100644
--- a/oslo_i18n/tests/test_message.py
+++ b/oslo_i18n/tests/test_message.py
@@ -386,7 +386,7 @@ class MessageTestCase(test_base.BaseTestCase):
self.assertEqual(default_translation, msg.translation('es'))
- self.assertEqual(1, len(w))
+ self.assertLessEqual(1, len(w))
# Note(gibi): in python 3.4 str.__repr__ does not put the unicode
# marker 'u' in front of the string representations so the test
# removes that to have the same result in python 2.7 and 3.4
@@ -394,7 +394,7 @@ class MessageTestCase(test_base.BaseTestCase):
"translated message A message in Spanish: %s %s "
"(Original: 'A message: %s'): "
"not enough arguments for format string",
- str(w[0].message).replace("u'", "'"))
+ str(w[-1].message).replace("u'", "'"))
mock_log.debug.assert_called_with(('Failed to insert replacement '
'values into translated message '
|