Skip to content

Commit

Permalink
remove duplicated test
Browse files Browse the repository at this point in the history
  • Loading branch information
florian-huber committed Nov 21, 2024
1 parent f70fbc3 commit bce7ad4
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,27 +45,6 @@ def test_join_arrays_join_types(join_type, expected_data, expected_row):
assert np.allclose(row, expected_row)


@pytest.mark.parametrize("join_type, expected_data, expected_row", [
["left", np.array([[0, 0], [1, 0], [2, 2], [4, 0], [5, 5]]), np.array([0, 1, 2, 4, 5])],
["right", np.array([[2, 2],[0, 3], [5, 5], [0, 6], [0, 7],]), np.array([2, 3, 5, 6, 7])],
["inner", np.array([[2, 2], [5, 5]]), np.array([2, 5])],
["outer", np.array([[0, 0], [1, 0], [2, 2], [0, 3], [4, 0], [5, 5], [0, 6], [0, 7]]),
np.array([0, 1, 2, 3, 4, 5, 6, 7])],
])
def test_join_arrays_join_types(join_type, expected_data, expected_row):
row1 = np.array([0, 1, 2, 4, 5])
col1 = np.array([0, 1, 2, 4, 5])
row2 = np.array([7, 5, 3, 6, 2])
col2 = np.array([7, 5, 3, 6, 2])
data1 = np.array(col1, dtype=[("layer1", col1.dtype)])
data2 = np.array(col2, dtype=[("layer2", col2.dtype)])

row, col, data = join_arrays(row1, col1, data1, row2, col2, data2, "test1",
join_type=join_type)
assert np.allclose(np.array([[x[0], x[1]] for x in data]), expected_data)
assert np.allclose(row, expected_row)


@pytest.mark.parametrize("join_type", [
"left", "right", "inner", "outer"
])
Expand Down

0 comments on commit bce7ad4

Please sign in to comment.