drop support for old Python, IPython < 3

Require IPython >= 3.0, Python >= 3.3
This commit is contained in:
Min RK
2014-10-31 13:03:50 -07:00
parent 83569221b9
commit 40a99e61ac
20 changed files with 110 additions and 173 deletions

View File

@@ -1,6 +1,5 @@
"""Test the JupyterHubApp entry point"""
import io
import os
import sys
from subprocess import check_output
@@ -8,8 +7,8 @@ from tempfile import NamedTemporaryFile
def test_help_all():
out = check_output([sys.executable, '-m', 'jupyterhub', '--help-all']).decode('utf8', 'replace')
assert u'--ip' in out
assert u'--JupyterHubApp.ip' in out
assert '--ip' in out
assert '--JupyterHubApp.ip' in out
def test_generate_config():
with NamedTemporaryFile(prefix='jupyter_hub_config', suffix='.py') as tf:
@@ -19,7 +18,7 @@ def test_generate_config():
'--generate-config', '-f', cfg_file]
).decode('utf8', 'replace')
assert os.path.exists(cfg_file)
with io.open(cfg_file) as f:
with open(cfg_file) as f:
cfg_text = f.read()
os.remove(cfg_file)
assert cfg_file in out