Lines Matching refs:setitem
73 def setitem(value): function
75 self.assertRaises(TypeError, setitem, b"a")
76 self.assertRaises(TypeError, setitem, 65)
77 self.assertRaises(TypeError, setitem, memoryview(b"a"))
104 def setitem(key, value): function
107 self.assertRaises(IndexError, setitem, 6, b"a")
108 self.assertRaises(IndexError, setitem, -7, b"a")
109 self.assertRaises(IndexError, setitem, sys.maxsize, b"a")
110 self.assertRaises(IndexError, setitem, -sys.maxsize, b"a")
112 self.assertRaises(TypeError, setitem, 0.0, b"a")
113 self.assertRaises(TypeError, setitem, (0,), b"a")
114 self.assertRaises(TypeError, setitem, "a", b"a")
116 self.assertRaises(ValueError, setitem, 0, b"")
117 self.assertRaises(ValueError, setitem, 0, b"ab")
118 self.assertRaises(ValueError, setitem, slice(1,1), b"a")
119 self.assertRaises(ValueError, setitem, slice(0,2), b"a")