@@ -159,7 +159,7 @@ def test_get_data_null_as_missing_data(self, adj_pr):
159159 else :
160160 floats .append ("Adj Close" )
161161
162- assert result [floats ].dtypes .all () == np .floating
162+ assert result [floats ].dtypes .all () == np .float64
163163
164164 @skip_on_exception (RemoteDataError )
165165 def test_get_data_multiple_symbols_two_dates (self ):
@@ -168,7 +168,7 @@ def test_get_data_multiple_symbols_two_dates(self):
168168 assert result .size == 3
169169
170170 # sanity checking
171- assert result .dtypes == np .floating
171+ assert result .dtypes == np .float64
172172
173173 expected = np .array (
174174 [
@@ -207,12 +207,12 @@ def test_get_data_yahoo_actions(self):
207207 assert actions .loc ["2005-02-28" , "value" ][0 ] == 1 / 2.0
208208
209209 assert actions .loc ["1995-11-21" , "action" ][0 ] == "DIVIDEND"
210- assert round (actions .loc ["1995-11-21" , "value" ][0 ], 3 ) == 0.120
210+ assert round (actions .loc ["1995-11-21" , "value" ][0 ], 3 ) == 0.030
211211
212212 actions = web .get_data_yahoo_actions ("AAPL" , start , end , adjust_dividends = True )
213213
214214 assert actions .loc ["1995-11-21" , "action" ][0 ] == "DIVIDEND"
215- assert round (actions .loc ["1995-11-21" , "value" ][0 ], 4 ) == 0.0043
215+ assert round (actions .loc ["1995-11-21" , "value" ][0 ], 4 ) == 0.0011
216216
217217 def test_get_data_yahoo_actions_invalid_symbol (self ):
218218 start = datetime (1990 , 1 , 1 )
@@ -226,14 +226,14 @@ def test_yahoo_reader_class(self):
226226 r = YahooDailyReader ("GOOG" , start = "JAN-01-2015" )
227227 df = r .read ()
228228
229- assert df .Volume .loc ["JAN-02-2015" ] == 1447500
229+ assert df .Volume .loc ["JAN-02-2015" ] == 1447563
230230
231231 session = requests .Session ()
232232
233233 r = YahooDailyReader ("GOOG" , session = session )
234234 assert r .session is session
235235
236- def test_yahoo_DataReader (self ):
236+ def test_yahoo_datareader (self ):
237237 start = datetime (2010 , 1 , 1 )
238238 end = datetime (2015 , 5 , 9 )
239239 # yahoo will adjust for dividends by default
@@ -275,19 +275,19 @@ def test_yahoo_DataReader(self):
275275 "DIVIDEND" ,
276276 ],
277277 "value" : [
278- 0.52 ,
279- 0.47 ,
280- 0.47 ,
281- 0.47 ,
282- 0.14285714 ,
283- 0.47 ,
284- 0.43571 ,
285- 0.43571 ,
286- 0.43571 ,
287- 0.43571 ,
288- 0.37857 ,
289- 0.37857 ,
290- 0.37857 ,
278+ 0.130000 ,
279+ 0.117500 ,
280+ 0.117500 ,
281+ 0.117500 ,
282+ 0.142857 ,
283+ 0.117500 ,
284+ 0.108929 ,
285+ 0.108929 ,
286+ 0.108929 ,
287+ 0.108929 ,
288+ 0.094643 ,
289+ 0.094643 ,
290+ 0.094643 ,
291291 ],
292292 },
293293 index = exp_idx ,
@@ -316,19 +316,19 @@ def test_yahoo_DataReader(self):
316316 "DIVIDEND" ,
317317 ],
318318 "value" : [
319- 0.52 ,
320- 0.47 ,
321- 0.47 ,
322- 0.47 ,
323- 0.14285714 ,
324- 3.29 ,
325- 3.05 ,
326- 3.05 ,
327- 3.05 ,
328- 3.05 ,
329- 2.65 ,
330- 2.65 ,
331- 2.65 ,
319+ 0.1300 ,
320+ 0.1175 ,
321+ 0.1175 ,
322+ 0.1175 ,
323+ 0.1429 ,
324+ 0.8225 ,
325+ 0.7625 ,
326+ 0.7625 ,
327+ 0.7625 ,
328+ 0.7625 ,
329+ 0.6625 ,
330+ 0.6625 ,
331+ 0.6625 ,
332332 ],
333333 },
334334 index = exp_idx ,
@@ -344,13 +344,13 @@ def test_yahoo_DataReader(self):
344344 result = web .DataReader ("NTR" , "yahoo-actions" , start , end )
345345
346346 exp_idx = pd .DatetimeIndex (
347- ["2018-12-28" , "2018-09-27" , "2018-06-28" , "2018-03-28" , "2018-01-02" ]
347+ ["2018-12-28" , "2018-09-27" , "2018-06-28" , "2018-03-28" ]
348348 )
349349
350350 exp = pd .DataFrame (
351351 {
352- "action" : ["DIVIDEND" , "DIVIDEND" , "DIVIDEND" , "DIVIDEND" , "SPLIT" ],
353- "value" : [0.43 , 0.40 , 0.40 , 0.40 , 1.00 ],
352+ "action" : ["DIVIDEND" , "DIVIDEND" , "DIVIDEND" , "DIVIDEND" ],
353+ "value" : [0.43 , 0.40 , 0.40 , 0.40 ],
354354 },
355355 index = exp_idx ,
356356 )
0 commit comments