def test_noncopyable_vector(): from pybind11_tests import get_vnc vnc = get_vnc(5) for i in range(0, 5): assert vnc[i].value == i + 1 for i, j in enumerate(vnc, start=1): assert j.value == i
def test_noncopyable_vector(): from pybind11_tests import ENC, get_vnc vnc = get_vnc(5) for i in range(0, 5): assert (vnc[i].value == i + 1) i = 1 for j in vnc: assert (j.value == i) i += 1