-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
CLN/TST: Cleanup tests in test_ujson.py #21739
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
CLN/TST: Cleanup tests in test_ujson.py #21739
Conversation
pandas/tests/io/json/test_ujson.py
Outdated
import locale | ||
savedlocale = locale.getlocale(locale.LC_NUMERIC) | ||
saved_locale = locale.getlocale(locale.LC_NUMERIC) | ||
|
||
try: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think we have a contest manager for locale setting
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Good point, but it doesn't do the
Exception
checking that I think this test wants to do. - I think I would want to tap into
_can_set_locale
instead. Any reason why I shouldn't utilize into this private method?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not familiar with that
but happy to use existing code (so u know why it’s private?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(so u know why it’s private?)
No clue 😄 , but I'll go ahead and make it public and use it instead.
06ae3da
to
d5f0f03
Compare
Codecov Report
@@ Coverage Diff @@
## master #21739 +/- ##
=======================================
Coverage 91.92% 91.92%
=======================================
Files 158 158
Lines 49705 49705
=======================================
Hits 45693 45693
Misses 4012 4012
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #21739 +/- ##
=========================================
Coverage ? 91.93%
=========================================
Files ? 159
Lines ? 49719
Branches ? 0
=========================================
Hits ? 45707
Misses ? 4012
Partials ? 0
Continue to review full report at Codecov.
|
a43d9b6
to
528d3d2
Compare
* Actually test the outputs * Add more parametrization * Take advantage of pytest features, such as exception contexts
528d3d2
to
30eb1fb
Compare
@jreback : Everything is green. PTAL. |
thanks @gfyoung nice cleanups! keep em coming! |
Backported from pandas-devgh-21739.
Backported from pandas-devgh-21739. Backport of pandas-devgh-22213.
* CI: Bump NumPy to 1.9.3 Backport of gh-22499. * BLD: Fix openpyxl to 2.5.5 Backport of gh-22601. * CI: Resolve timeout issue on Travis Backported from gh-22429. * CI: Migrate to CircleCI 2.0 Backport of gh-21814. * Upgrade Cython to >=0.28.2 Backported from gh-21688. * TST: Patch locale handling Backported from gh-21739. Backport of gh-22213.
pytest
features, such as exception contextsThis test module really needed an update 😄