diff options
author | Benjamin Peterson <benjamin@python.org> | 2014-03-13 22:37:55 -0500 |
---|---|---|
committer | Benjamin Peterson <benjamin@python.org> | 2014-03-13 22:37:55 -0500 |
commit | 324b371317f66a91094f58046f1a804701c50652 (patch) | |
tree | f91e33507ef96e7bbe50c9bd644f5b598deef665 /test_six.py | |
parent | 543f9487b9ce2db3ea4cd10cb5894e7e14fc137a (diff) | |
download | six-324b371317f66a91094f58046f1a804701c50652.tar.gz |
raise an AttributeError for six.moves.X when X is a module not available in the current interpreter
As discussed in https://github.com/pypa/pip/issues/1643.
Diffstat (limited to 'test_six.py')
-rw-r--r-- | test_six.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test_six.py b/test_six.py index 45649b2..47ad1ce 100644 --- a/test_six.py +++ b/test_six.py @@ -113,7 +113,8 @@ def test_move_items(item_name): if item_name.startswith("dbm_gnu") and not have_gdbm: py.test.skip("requires gdbm") raise - assert item_name in dir(six.moves) + if sys.version_info[:2] >= (2, 6): + assert item_name in dir(six.moves) @py.test.mark.parametrize("item_name", |