Skip to content

Commit

Permalink
Improve nydus test
Browse files Browse the repository at this point in the history
  • Loading branch information
spudde123 committed Mar 17, 2021
1 parent 029033b commit 55abe78
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/test_c_extension.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,13 @@ def test_c_extension():
Point2((29.5, 34.5))
]

influenced_grid[5:8, 5:8] = np.inf
influenced_grid[28:31, 33:36] = np.inf

paths_nydus = astar_path_with_nyduses(influenced_grid, (3, 3), (33, 38), nydus_positions, False, False)

assert (paths_nydus is not None and len(paths_nydus) == 2
and len(paths_nydus[0]) + len(paths_nydus[1]) == 8)
and len(paths_nydus[0]) + len(paths_nydus[1]) == 7)

height_map = np.where(walkable_grid == 0, 24, 8).astype(np.uint8)

Expand Down

0 comments on commit 55abe78

Please sign in to comment.