public void TestGetSlice() { var t = new PyString("FooBar"); PyObject s = t.GetSlice(0, 3); Assert.AreEqual("Foo", s.ToString()); PyObject s2 = t.GetSlice(3, 6); Assert.AreEqual("Bar", s2.ToString()); PyObject s3 = t.GetSlice(0, 6); Assert.AreEqual("FooBar", s3.ToString()); PyObject s4 = t.GetSlice(0, 12); Assert.AreEqual("FooBar", s4.ToString()); }