예제 #1
0
 def test_normalize_key_exception(self):
     a = VDFDict()
     with self.assertRaises(TypeError):
         a._normalize_key(5)
     with self.assertRaises(TypeError):
         a._normalize_key([])
     with self.assertRaises(TypeError):
         a._normalize_key(None)
예제 #2
0
 def test_normalize_key_exception(self):
     a = VDFDict()
     with self.assertRaises(TypeError):
         a._normalize_key(5)
     with self.assertRaises(TypeError):
         a._normalize_key([])
     with self.assertRaises(TypeError):
         a._normalize_key(None)
예제 #3
0
 def test_normalize_key(self):
     a = VDFDict()
     self.assertEqual(a._normalize_key('AAA'), (0, 'AAA'))
     self.assertEqual(a._normalize_key((5, 'BBB')), (5, 'BBB'))
예제 #4
0
 def test_normalize_key(self):
     a = VDFDict()
     self.assertEqual(a._normalize_key('AAA'), (0, 'AAA'))
     self.assertEqual(a._normalize_key((5, 'BBB')), (5, 'BBB'))