Skip to content

Commit

Permalink
chore: fix test dtype issue
Browse files Browse the repository at this point in the history
  • Loading branch information
mdtanker committed May 7, 2024
1 parent 7f4c863 commit f16f955
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,12 @@ def test_sample_grids_on_nodes():
df = pd.DataFrame({"x": [0, 100, 200], "y": [200, 300, 400]})
result_df = utils.sample_grids(df, grid, sampled_name=name)
expected = pd.DataFrame(
{"x": [0, 100, 200], "y": [200, 300, 400], name: [40000, 100000, 200000]}
{
"x": [0, 100, 200],
"y": [200, 300, 400],
name: [40000, 100000, 200000],
},
dtype="int",
)
pdt.assert_frame_equal(result_df, expected)

Expand Down Expand Up @@ -448,7 +453,8 @@ def test_sample_grids_custom_coordinate_names():
df, grid, sampled_name=name, coord_names=("lon", "lat")
)
expected = pd.DataFrame(
{"lon": [0, 100, 200], "lat": [200, 300, 400], name: [40000, 100000, 200000]}
{"lon": [0, 100, 200], "lat": [200, 300, 400], name: [40000, 100000, 200000]},
dtype="int",
)
pdt.assert_frame_equal(result_df, expected)

Expand Down

0 comments on commit f16f955

Please sign in to comment.