@@ -6617,11 +6617,11 @@ def test_rolling_wrapped_bottleneck_center_pad(da, name, center, pad):
66176617 pytest .importorskip ("bottleneck" , minversion = "1.1" )
66186618
66196619 window = 7
6620- count = len (da ["time" ])
6620+ length = len (da ["time" ])
66216621 rolling_obj = da .rolling (time = 7 , center = center , pad = pad )
66226622 actual = getattr (rolling_obj , name )()["time" ]
66236623
6624- expected_index = get_expected_rolling_indices (count , window , center , pad )
6624+ expected_index = get_expected_rolling_indices (length , window , center , pad )
66256625 expected = da ["time" ][expected_index ]
66266626
66276627 assert_equal (actual , expected )
@@ -6712,10 +6712,10 @@ def test_rolling_pandas_compat(center, pad, window, min_periods):
67126712@pytest .mark .parametrize ("center" , (True , False ))
67136713@pytest .mark .parametrize ("window" , (2 , 3 , 4 ))
67146714def test_rolling_construct (center , window ):
6715- count = 10
6716- s = pd .Series (np .arange (count ))
6715+ length = 10
6716+ s = pd .Series (np .arange (length ))
67176717 da = DataArray .from_series (s )
6718- da = da .assign_coords (time = ("index" , np .arange (1 , count + 1 )))
6718+ da = da .assign_coords (time = ("index" , np .arange (1 , length + 1 )))
67196719
67206720 s_rolling = s .rolling (window , center = center , min_periods = 1 ).mean ()
67216721 da_rolling = da .rolling (index = window , center = center , min_periods = 1 )
@@ -6741,7 +6741,7 @@ def test_rolling_construct(center, window):
67416741 da_rolling_mean = da_rolling .construct ("window" , stride = 2 ).mean ("window" )
67426742
67436743 expected_index = get_expected_rolling_indices (
6744- count , window , center , pad = False , stride = 2
6744+ length , window , center , pad = False , stride = 2
67456745 )
67466746
67476747 assert da_rolling_mean .sizes ["index" ] == len (expected_index )
0 commit comments