Lines Matching refs:setitem
66 def setitem(value): function
68 self.assertRaises(TypeError, setitem, b"a")
69 self.assertRaises(TypeError, setitem, 65)
70 self.assertRaises(TypeError, setitem, memoryview(b"a"))
99 def setitem(key, value): function
102 self.assertRaises(IndexError, setitem, 6, b"a")
103 self.assertRaises(IndexError, setitem, -7, b"a")
104 self.assertRaises(IndexError, setitem, sys.maxsize, b"a")
105 self.assertRaises(IndexError, setitem, -sys.maxsize, b"a")
107 self.assertRaises(TypeError, setitem, 0.0, b"a")
108 self.assertRaises(TypeError, setitem, (0,), b"a")
109 self.assertRaises(TypeError, setitem, (slice(0,1,1), 0), b"a")
110 self.assertRaises(TypeError, setitem, (0, slice(0,1,1)), b"a")
111 self.assertRaises(TypeError, setitem, (0,), b"a")
112 self.assertRaises(TypeError, setitem, "a", b"a")
115 self.assertRaises(NotImplementedError, setitem, slices, b"a")
118 self.assertRaises(exc, setitem, 0, b"")
119 self.assertRaises(exc, setitem, 0, b"ab")
120 self.assertRaises(ValueError, setitem, slice(1,1), b"a")
121 self.assertRaises(ValueError, setitem, slice(0,2), b"a")