Ejemplo n.º 1
0
 def test_translate(self):
     machine_translation = DummyTranslation()
     self.assertEqual(
         machine_translation.translate('cs', 'Hello', None),
         []
     )
     self.assertEqual(
         len(machine_translation.translate('cs', 'Hello, world!', None)),
         2
     )
Ejemplo n.º 2
0
 def test_translate(self):
     machine_translation = DummyTranslation()
     self.assertEqual(machine_translation.translate('cs', 'Hello', None),
                      [])
     self.assertEqual(
         len(machine_translation.translate('cs', 'Hello, world!', None)), 2)
Ejemplo n.º 3
0
 def test_support(self):
     machine_translation = DummyTranslation()
     self.assertTrue(machine_translation.is_supported('cs'))
     self.assertFalse(machine_translation.is_supported('de'))
Ejemplo n.º 4
0
 def test_support(self):
     machine_translation = DummyTranslation()
     self.assertTrue(machine_translation.is_supported('cs'))
     self.assertFalse(machine_translation.is_supported('de'))