@@ -54,16 +54,14 @@ def describe_with_api_key():
5454 @responses .activate
5555 def when_valid ():
5656 client = blueskyapi .Client (api_key = "the-key" )
57- add_api_response (
58- "/forecasts/gfs_0p25/latest?lat=53.5&lon=13.5" , api_key = "the-key"
59- )
57+ add_api_response ("/forecasts/latest?lat=53.5&lon=13.5" , api_key = "the-key" )
6058 client .latest_forecast (53.5 , 13.5 )
6159
6260 @responses .activate
6361 def when_invalid ():
6462 client = blueskyapi .Client (api_key = "the-key" )
6563 add_api_response (
66- "/forecasts/gfs_0p25/ latest?lat=53.5&lon=13.5" ,
64+ "/forecasts/latest?lat=53.5&lon=13.5" ,
6765 api_key = "the-key" ,
6866 result = {"detail" : "Invalid API key" },
6967 status = 401 ,
@@ -75,21 +73,21 @@ def when_invalid():
7573def describe_latest_forecast ():
7674 @responses .activate
7775 def test_defaults (client ):
78- add_api_response ("/forecasts/gfs_0p25/ latest?lat=53.5&lon=13.5" )
76+ add_api_response ("/forecasts/latest?lat=53.5&lon=13.5" )
7977 client .latest_forecast (53.5 , 13.5 )
8078
8179 def describe_forecast_distances ():
8280 @responses .activate
8381 def with_array (client ):
8482 add_api_response (
85- "/forecasts/gfs_0p25/ latest?lat=53.5&lon=13.5&forecast_distances=0,24"
83+ "/forecasts/latest?lat=53.5&lon=13.5&forecast_distances=0,24"
8684 )
8785 client .latest_forecast (53.5 , 13.5 , forecast_distances = [0 , 24 ])
8886
8987 @responses .activate
9088 def with_string (client ):
9189 add_api_response (
92- "/forecasts/gfs_0p25/ latest?lat=53.5&lon=13.5&forecast_distances=0,24"
90+ "/forecasts/latest?lat=53.5&lon=13.5&forecast_distances=0,24"
9391 )
9492 client .latest_forecast (53.5 , 13.5 , forecast_distances = "0,24" )
9593
@@ -101,16 +99,12 @@ def with_invalid_value(client):
10199 def describe_columns ():
102100 @responses .activate
103101 def with_array (client ):
104- add_api_response (
105- "/forecasts/gfs_0p25/latest?lat=53.5&lon=13.5&columns=col_a,col_b"
106- )
102+ add_api_response ("/forecasts/latest?lat=53.5&lon=13.5&columns=col_a,col_b" )
107103 client .latest_forecast (53.5 , 13.5 , columns = ["col_a" , "col_b" ])
108104
109105 @responses .activate
110106 def with_string (client ):
111- add_api_response (
112- "/forecasts/gfs_0p25/latest?lat=53.5&lon=13.5&columns=col_a,col_b"
113- )
107+ add_api_response ("/forecasts/latest?lat=53.5&lon=13.5&columns=col_a,col_b" )
114108 client .latest_forecast (53.5 , 13.5 , columns = "col_a,col_b" )
115109
116110 @responses .activate
@@ -121,7 +115,7 @@ def with_invalid_value(client):
121115 @responses .activate
122116 def test_over_rate_limit (client ):
123117 add_api_response (
124- "/forecasts/gfs_0p25/ latest?lat=53.5&lon=13.5" ,
118+ "/forecasts/latest?lat=53.5&lon=13.5" ,
125119 result = {"the" : "error" },
126120 status = 429 ,
127121 )
@@ -131,7 +125,7 @@ def test_over_rate_limit(client):
131125 @responses .activate
132126 def test_result (client ):
133127 add_api_response (
134- "/forecasts/gfs_0p25/ latest?lat=53.5&lon=13.5" ,
128+ "/forecasts/latest?lat=53.5&lon=13.5" ,
135129 result = [{"forecast_moment" : "2021-12-27T18:00:00Z" , "some_column" : 5 }],
136130 )
137131 result = client .latest_forecast (53.5 , 13.5 )
@@ -165,7 +159,7 @@ def describe_min_forecast_moments():
165159 @responses .activate
166160 def with_datetime (client ):
167161 add_api_response (
168- "/forecasts/gfs_0p25/ history"
162+ "/forecasts/history"
169163 "?lat=53.5&lon=13.5"
170164 "&min_forecast_moment=2021-12-27T18:00:00"
171165 "&max_forecast_moment=2021-12-28T00:00:00"
@@ -180,7 +174,7 @@ def with_datetime(client):
180174 @responses .activate
181175 def with_string (client ):
182176 add_api_response (
183- "/forecasts/gfs_0p25/ history"
177+ "/forecasts/history"
184178 "?lat=53.5&lon=13.5"
185179 "&min_forecast_moment=2021-12-27T18:00:00"
186180 "&max_forecast_moment=2021-12-28T00:00:00"
@@ -201,7 +195,7 @@ def describe_max_forecast_moments():
201195 @responses .activate
202196 def with_none (client ):
203197 add_api_response (
204- "/forecasts/gfs_0p25/ history"
198+ "/forecasts/history"
205199 "?lat=53.5&lon=13.5"
206200 "&min_forecast_moment=2021-12-27T18:00:00"
207201 )
0 commit comments