Lines Matching refs:cistr
2851 class cistr(str):
2862 if not isinstance(other, cistr):
2863 other = cistr(other)
2869 self.assertEqual(cistr('ABC'), 'abc')
2870 self.assertEqual('aBc', cistr('ABC'))
2871 self.assertEqual(str(cistr('ABC')), 'ABC')
2873 d = {cistr('one'): 1, cistr('two'): 2, cistr('tHree'): 3}
2874 self.assertEqual(d[cistr('one')], 1)
2875 self.assertEqual(d[cistr('tWo')], 2)
2876 self.assertEqual(d[cistr('THrEE')], 3)
2877 self.assertIn(cistr('ONe'), d)
2878 self.assertEqual(d.get(cistr('thrEE')), 3)