Show More
@@ -126,13 +126,14 b' with_environment = with_setup(setup_environment, teardown_environment)' | |||||
126 | def test_get_home_dir_1(): |
|
126 | def test_get_home_dir_1(): | |
127 | """Testcase for py2exe logic, un-compressed lib |
|
127 | """Testcase for py2exe logic, un-compressed lib | |
128 | """ |
|
128 | """ | |
|
129 | unfrozen = path.get_home_dir() | |||
129 | sys.frozen = True |
|
130 | sys.frozen = True | |
130 |
|
131 | |||
131 | #fake filename for IPython.__init__ |
|
132 | #fake filename for IPython.__init__ | |
132 | IPython.__file__ = abspath(join(HOME_TEST_DIR, "Lib/IPython/__init__.py")) |
|
133 | IPython.__file__ = abspath(join(HOME_TEST_DIR, "Lib/IPython/__init__.py")) | |
133 |
|
134 | |||
134 | home_dir = path.get_home_dir() |
|
135 | home_dir = path.get_home_dir() | |
135 |
nt.assert_equal(home_dir, |
|
136 | nt.assert_equal(home_dir, unfrozen) | |
136 |
|
137 | |||
137 |
|
138 | |||
138 | @skip_if_not_win32 |
|
139 | @skip_if_not_win32 | |
@@ -140,12 +141,13 b' def test_get_home_dir_1():' | |||||
140 | def test_get_home_dir_2(): |
|
141 | def test_get_home_dir_2(): | |
141 | """Testcase for py2exe logic, compressed lib |
|
142 | """Testcase for py2exe logic, compressed lib | |
142 | """ |
|
143 | """ | |
|
144 | unfrozen = path.get_home_dir() | |||
143 | sys.frozen = True |
|
145 | sys.frozen = True | |
144 | #fake filename for IPython.__init__ |
|
146 | #fake filename for IPython.__init__ | |
145 | IPython.__file__ = abspath(join(HOME_TEST_DIR, "Library.zip/IPython/__init__.py")).lower() |
|
147 | IPython.__file__ = abspath(join(HOME_TEST_DIR, "Library.zip/IPython/__init__.py")).lower() | |
146 |
|
148 | |||
147 | home_dir = path.get_home_dir(True) |
|
149 | home_dir = path.get_home_dir(True) | |
148 |
nt.assert_equal(home_dir, |
|
150 | nt.assert_equal(home_dir, unfrozen) | |
149 |
|
151 | |||
150 |
|
152 | |||
151 | @with_environment |
|
153 | @with_environment |
General Comments 0
You need to be logged in to leave comments.
Login now