def test_index_negative(self): s = SortedSet([1, 5, 7, 9]) with self.assertRaises(ValueError): s.index(15)
def test_index_positive(self): s = SortedSet([1, 5, 7, 9]) self.assertEqual(s.index(7), 2)