def METHOD_NAME(self):
    s = self.type2test("foo")
    self.assertRaises(IndexError, s.__setitem__, -4, "bar")
    self.assertRaises(IndexError, s.__setitem__, 3, "bar")
    s[-1] = "bar"
    self.assertEqual(s, "fobar")
    s[0] = "bar"
    self.assertEqual(s, "barobar")