From 597507ae426688f3f54b5839376ca7dac0065e39 2014-02-04 19:37:02 From: MinRK Date: 2014-02-04 19:37:02 Subject: [PATCH] skip Python 2.6 in test_profile because python -m doesn't work --- diff --git a/IPython/core/tests/test_profile.py b/IPython/core/tests/test_profile.py index 4619103..c22538f 100644 --- a/IPython/core/tests/test_profile.py +++ b/IPython/core/tests/test_profile.py @@ -26,7 +26,6 @@ import shutil import sys import tempfile -from subprocess import check_output from unittest import TestCase import nose.tools as nt @@ -154,11 +153,13 @@ def test_list_bundled_profiles(): nt.assert_equal(bundled, bundled_true) +@dec.skipif(sys.version_info < (2,7), "python -m doesn't work on 2.6") def test_profile_create_ipython_dir(): """ipython profile create respects --ipython-dir""" + from subprocess import check_output, STDOUT with TemporaryDirectory() as td: check_output([sys.executable, '-m', 'IPython', 'profile', 'create', - 'foo', '--ipython-dir=%s' % td]) + 'foo', '--ipython-dir=%s' % td], stderr=STDOUT) profile_dir = os.path.join(td, 'profile_foo') assert os.path.exists(profile_dir) ipython_config = os.path.join(profile_dir, 'ipython_config.py')