Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor GoogleQuotesReader #188

Merged
merged 1 commit into from Mar 10, 2016
Merged

Refactor GoogleQuotesReader #188

merged 1 commit into from Mar 10, 2016

Conversation

gliptak
Copy link
Contributor

@gliptak gliptak commented Mar 2, 2016

def test_get_quote_string(self):
df = web.get_quote_google('GOOG')
self.assertTrue(df.ix['GOOG']['last'] > 0.0)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pls test index and columns are correct using tm.assert_index_equal also in test_get_quote_stringlist.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

@femtotrader
Copy link
Contributor

Thanks @gliptak but you might add some tests to ensure type of returned data.

  • time is probably a datetime.time
  • change_pct and last a float or a Decimal

@sinhrks
Copy link
Member

sinhrks commented Mar 6, 2016

No, dtypes will be float, float, datetime[ns]. #188 adds a similar dtype test.

Using Decimal is regarded as obejct internally, and it causes some numeric ops not work.

@gliptak
Copy link
Contributor Author

gliptak commented Mar 6, 2016

Thanks for the pointers. Please review update.

@gliptak
Copy link
Contributor Author

gliptak commented Mar 6, 2016

@gliptak
Copy link
Contributor Author

gliptak commented Mar 7, 2016

Some code gymnastics ...

@gliptak
Copy link
Contributor Author

gliptak commented Mar 9, 2016

Any other changes you would like? Thanks

@femtotrader
Copy link
Contributor

Sounds good to me. And you @sinhrks ? Can you squash commits @gliptak ?

@gliptak
Copy link
Contributor Author

gliptak commented Mar 9, 2016

Squashed.

numpy/numpy#7390

femtotrader added a commit that referenced this pull request Mar 10, 2016
ENH: Refactor GoogleQuotesReader
@femtotrader femtotrader merged commit b83430d into pydata:master Mar 10, 2016
@femtotrader
Copy link
Contributor

Thanks @gliptak

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants