def test_empty(self): self.failUnless(jsonops.array_slice([], "[1:2]") == jsonops.pprint([]))
def test_normal_slice(self): self.failUnless( jsonops.array_slice(range(10), "[3:5]") == jsonops.pprint([3, 4]))
def test_reverse_range(self): self.failUnless( jsonops.array_slice(range(10), "[9:1]") == jsonops.pprint([]))
def test_one(self): self.failUnless( jsonops.array_slice([1], "[0:1]") == jsonops.pprint([1]))
def test_empty(self): self.failUnless( jsonops.array_slice([], "[1:2]") == jsonops.pprint([]))
def test_reverse_range(self): self.failUnless( jsonops.array_slice(range(10), "[9:1]") == jsonops.pprint([]))
def test_normal_slice(self): self.failUnless( jsonops.array_slice(range(10), "[3:5]") == jsonops.pprint([3, 4]))
def test_one(self): self.failUnless( jsonops.array_slice([1], "[0:1]") == jsonops.pprint([1]))