Skip to content

Commit ea6e3d7

Browse files
committed
don't use loc to avoid a future warning about calling int on a single element series
1 parent 479f8f4 commit ea6e3d7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hhs_hosp/tests/test_run.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ def test_transform_signal_pop():
100100
'timestamp': [datetime(year=2020, month=1, day=1)]*2,
101101
'val': [15., 150.],})
102102

103-
pa_pop = int(state_pop.loc[state_pop.state_id == "pa", "pop"])
104-
wv_pop = int(state_pop.loc[state_pop.state_id == "wv", "pop"])
103+
pa_pop = int(state_pop[state_pop.state_id == "pa"]["pop"].iloc[0])
104+
wv_pop = int(state_pop[state_pop.state_id == "wv"]["pop"].iloc[0])
105105
pd.testing.assert_frame_equal(
106106
transform_signal(
107107
CONFIRMED_PROP,

0 commit comments

Comments
 (0)