##// END OF EJS Templates
- Test case correctly fails....
Alcides -
Show More
@@ -111,12 +111,18 b' class TestMagicRunPass(tt.TempFileMixin):'
111 def setup(self):
111 def setup(self):
112 """Make a valid python temp file."""
112 """Make a valid python temp file."""
113 self.mktmp('pass\n')
113 self.mktmp('pass\n')
114
114
115 def run_tmpfile(self):
115 def run_tmpfile(self):
116 _ip = get_ipython()
116 _ip = get_ipython()
117 # This fails on Windows if self.tmpfile.name has spaces or "~" in it.
117 # This fails on Windows if self.tmpfile.name has spaces or "~" in it.
118 # See below and ticket https://bugs.launchpad.net/bugs/366353
118 # See below and ticket https://bugs.launchpad.net/bugs/366353
119 _ip.magic('run %s' % self.fname)
119 _ip.magic('run %s' % self.fname)
120
121 def run_tmpfile_p(self):
122 _ip = get_ipython()
123 # This fails on Windows if self.tmpfile.name has spaces or "~" in it.
124 # See below and ticket https://bugs.launchpad.net/bugs/366353
125 _ip.magic('run -p %s' % self.fname)
120
126
121 def test_builtins_id(self):
127 def test_builtins_id(self):
122 """Check that %run doesn't damage __builtins__ """
128 """Check that %run doesn't damage __builtins__ """
@@ -144,6 +150,12 b' class TestMagicRunPass(tt.TempFileMixin):'
144 _ip = get_ipython()
150 _ip = get_ipython()
145 p2 = str(_ip.displayhook.prompt2).strip()
151 p2 = str(_ip.displayhook.prompt2).strip()
146 nt.assert_equals(p2[:3], '...')
152 nt.assert_equals(p2[:3], '...')
153
154 def test_run_profile( self ):
155 """Test that the option -p, which invokes the profiler, do not
156 crash by invoking execfile"""
157 _ip = get_ipython()
158 self.run_tmpfile_p()
147
159
148
160
149 class TestMagicRunSimple(tt.TempFileMixin):
161 class TestMagicRunSimple(tt.TempFileMixin):
General Comments 0
You need to be logged in to leave comments. Login now