def test_no_len_on_UserList_iter_reversed(self):
    import sys, _abcoll
    sys.modules['collections'] = _abcoll
    from UserList import UserList
    iterable = UserList([1, 2, 3, 4])
    raises(TypeError, len, iter(iterable))
    raises(TypeError, len, reversed(iterable))
    del sys.modules['collections']
def test_no_len_on_UserList_iter_reversed(self):
    import sys, _abcoll
    sys.modules['collections'] = _abcoll
    from UserList import UserList
    iterable = UserList([1, 2, 3, 4])
    raises(TypeError, len, iter(iterable))
    raises(TypeError, len, reversed(iterable))
    del sys.modules['collections']