##// END OF EJS Templates
added test for GH-284: ensure In variable is works
Paul Ivanov -
Show More
@@ -71,6 +71,15 b' class InteractiveShellTestCase(unittest.TestCase):'
71 newlen = len(ip.user_ns['Out'])
71 newlen = len(ip.user_ns['Out'])
72 self.assertEquals(oldlen, newlen)
72 self.assertEquals(oldlen, newlen)
73 #also test the default caching behavior
73 #also test the default caching behavior
74 a = ip.run_cell('1')
74 ip.run_cell('1')
75 newlen = len(ip.user_ns['Out'])
75 newlen = len(ip.user_ns['Out'])
76 self.assertEquals(oldlen+1, newlen)
76 self.assertEquals(oldlen+1, newlen)
77
78 def test_In_variable(self):
79 "Verify that In variable grows with user input (GH-284)"
80 ip = get_ipython()
81 oldlen = len(ip.user_ns['In'])
82 ip.run_cell('1;')
83 newlen = len(ip.user_ns['In'])
84 self.assertEquals(oldlen+1, newlen)
85 self.assertEquals(ip.user_ns['In'][-1],'1;')
General Comments 0
You need to be logged in to leave comments. Login now