Skip to content

DEPS: Drop Python 3.4 support #16303

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

Merged
merged 2 commits into from
May 16, 2017
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
TST: Patch locale failure on Circle
  • Loading branch information
gfyoung committed May 15, 2017
commit 9c33e44e473b83bb14635675ac25a072fd400557
6 changes: 0 additions & 6 deletions ci/requirements-3.6_SLOW.build

This file was deleted.

Empty file removed ci/requirements-3.6_SLOW.pip
Empty file.
22 changes: 0 additions & 22 deletions ci/requirements-3.6_SLOW.run

This file was deleted.

19 changes: 10 additions & 9 deletions pandas/tests/util/test_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@

import pandas.util.testing as tm

CURRENT_LOCALE = locale.getlocale()
LOCALE_OVERRIDE = os.environ.get('LOCALE_OVERRIDE', None)


class TestDecorators(object):

Expand Down Expand Up @@ -412,6 +409,7 @@ class TestLocaleUtils(object):
@classmethod
def setup_class(cls):
cls.locales = tm.get_locales()
cls.current_locale = locale.getlocale()

if not cls.locales:
pytest.skip("No locales found")
Expand All @@ -421,6 +419,7 @@ def setup_class(cls):
@classmethod
def teardown_class(cls):
del cls.locales
del cls.current_locale

def test_get_locales(self):
# all systems should have at least a single locale
Expand All @@ -438,17 +437,19 @@ def test_set_locale(self):
pytest.skip("Only a single locale found, no point in "
"trying to test setting another locale")

if all(x is None for x in CURRENT_LOCALE):
if all(x is None for x in self.current_locale):
# Not sure why, but on some travis runs with pytest,
# getlocale() returned (None, None).
pytest.skip("CURRENT_LOCALE is not set.")
pytest.skip("Current locale is not set.")

locale_override = os.environ.get('LOCALE_OVERRIDE', None)

if LOCALE_OVERRIDE is None:
if locale_override is None:
lang, enc = 'it_CH', 'UTF-8'
elif LOCALE_OVERRIDE == 'C':
elif locale_override == 'C':
lang, enc = 'en_US', 'ascii'
else:
lang, enc = LOCALE_OVERRIDE.split('.')
lang, enc = locale_override.split('.')

enc = codecs.lookup(enc).name
new_locale = lang, enc
Expand All @@ -465,4 +466,4 @@ def test_set_locale(self):
assert normalized_locale == new_locale

current_locale = locale.getlocale()
assert current_locale == CURRENT_LOCALE
assert current_locale == self.current_locale