(self)
| 1920 | self.assertEqual(b, b'A') |
| 1921 | |
| 1922 | def test_insert(self): |
| 1923 | b = bytearray(b'msssspp') |
| 1924 | b.insert(1, ord('i')) |
| 1925 | b.insert(4, ord('i')) |
| 1926 | b.insert(-2, ord('i')) |
| 1927 | b.insert(1000, ord('i')) |
| 1928 | self.assertEqual(b, b'mississippi') |
| 1929 | self.assertRaises(TypeError, lambda: b.insert(0, b'1')) |
| 1930 | b = bytearray() |
| 1931 | b.insert(0, Indexable(ord('A'))) |
| 1932 | self.assertEqual(b, b'A') |
| 1933 | |
| 1934 | def test_copied(self): |
| 1935 | # Issue 4348. Make sure that operations that don't mutate the array |
nothing calls this directly
no test coverage detected