11
11
from requests import HTTPError
12
12
from io import StringIO
13
13
import warnings
14
- from pvlib ._deprecation import pvlibDeprecationWarning
15
14
16
15
TMY_TEST_DATA = DATA_DIR / 'test_goes4_tmy-2023.csv'
17
16
YEAR_TEST_DATA = DATA_DIR / 'test_goes4_2023.csv'
@@ -138,8 +137,8 @@ def test_get_goes4_tmy_errors(
138
137
"""
139
138
with pytest .raises (HTTPError ) as excinfo :
140
139
goes4 .get_goes4 (latitude , longitude , api_key , PVLIB_EMAIL ,
141
- names = names , interval = interval , leap_day = False ,
142
- map_variables = False )
140
+ names = names , interval = interval , leap_day = False ,
141
+ map_variables = False )
143
142
# ensure the HTTPError caught isn't due to overuse of the API key
144
143
assert "OVER_RATE_LIMIT" not in str (excinfo .value )
145
144
@@ -175,7 +174,7 @@ def test_read_goes4_map_variables():
175
174
'ghi_clear' , 'Cloud Fill Flag' , 'Cloud Type' ,
176
175
'temp_dew' , 'dhi' , 'dni' , 'Fill Flag' , 'ghi' , 'Ozone' ,
177
176
'relative_humidity' , 'solar_zenith' , 'SSA' , 'albedo' ,
178
- 'pressure' ,'precipitable_water' , 'wind_direction' ,
177
+ 'pressure' , 'precipitable_water' , 'wind_direction' ,
179
178
'wind_speed' ]
180
179
assert_index_equal (data .columns , pd .Index (columns_mapped ))
181
180
@@ -185,10 +184,10 @@ def test_read_goes4_map_variables():
185
184
def test_get_goes4_attribute_mapping (nrel_api_key ):
186
185
"""Test that pvlib names can be passed in as attributes and get correctly
187
186
reverse mapped to GOES4 names"""
188
- data , meta = goes4 .get_goes4 (LATITUDE , LONGITUDE , nrel_api_key , PVLIB_EMAIL ,
189
- names = 2019 , interval = 60 ,
190
- attributes = ['ghi' , 'wind_speed' ],
191
- leap_day = False , map_variables = True )
187
+ data , meta = goes4 .get_goes4 (LATITUDE , LONGITUDE , nrel_api_key ,
188
+ PVLIB_EMAIL , names = 2019 , interval = 60 ,
189
+ attributes = ['ghi' , 'wind_speed' ],
190
+ leap_day = False , map_variables = True )
192
191
# Check that columns are in the correct order (GH1647)
193
192
expected_columns = [
194
193
'Year' , 'Month' , 'Day' , 'Hour' , 'Minute' , 'ghi' , 'wind_speed' ]
0 commit comments