def test_substring(self):
     self.assertJson(query.substring("bulawayo", 0, 3),
                     '{"length":3,"start":0,"substring":"bulawayo"}')
Exemplo n.º 2
0
 def test_substring(self):
     self.assertEqual(self._q(query.substring("ABCDEF", -3)), "DEF")
     self.assertEqual(self._q(query.substring("ABCDEF", 0, 3)), "ABC")