From 18d1c6c7697d6cd6976e9293bb98b387996afb51 2015-03-25 18:08:14 From: Min RK Date: 2015-03-25 18:08:14 Subject: [PATCH] Backport PR #8121: fix compress_user comparison move `.lower()` outside compress_user, otherwise it can prevent the substition, e.g. on OS X, where home is `/Users/[name]` --- diff --git a/IPython/core/tests/test_oinspect.py b/IPython/core/tests/test_oinspect.py index 1d7f7bc..d8f1dd3 100644 --- a/IPython/core/tests/test_oinspect.py +++ b/IPython/core/tests/test_oinspect.py @@ -243,7 +243,7 @@ def test_info(): fname = fname[:-1] # case-insensitive comparison needed on some filesystems # e.g. Windows: - nt.assert_equal(i['file'].lower(), compress_user(fname.lower())) + nt.assert_equal(i['file'].lower(), compress_user(fname).lower()) nt.assert_equal(i['definition'], None) nt.assert_equal(i['docstring'], Call.__doc__) nt.assert_equal(i['source'], None)