def test_construct_arg(): arg = (1, 2, 3, 4, 5, 6) pos = np.array([0, 2, 4], dtype=np.int) carg = construct_arg(arg, pos) expected = (1, 3, 5) # print carg for i in range(len(carg)): assert_almost_equal(carg[i], expected[i])
def test_construct_arg(): arg = (1, 2, 3, 4, 5, 6) pos = np.array([0, 2, 4], dtype=np.int) carg = construct_arg(arg, pos) assert carg == (1, 3, 5)