##// END OF EJS Templates
added test for GH-306
Paul Ivanov -
Show More
@@ -35,14 +35,14 b' class InteractiveShellTestCase(unittest.TestCase):'
35 35 # And also multi-line cells
36 36 ip.run_cell('"""a\nb"""\n')
37 37 self.assertEquals(ip.user_ns['_'], 'a\nb')
38
38
39 39 def test_run_empty_cell(self):
40 40 """Just make sure we don't get a horrible error with a blank
41 41 cell of input. Yes, I did overlook that."""
42 42 ip = get_ipython()
43 43 ip.run_cell('')
44 44
45 def test_run_cell_multilne(self):
45 def test_run_cell_multiline(self):
46 46 """Multi-block, multi-line cells must execute correctly.
47 47 """
48 48 ip = get_ipython()
@@ -54,4 +54,11 b' class InteractiveShellTestCase(unittest.TestCase):'
54 54 ip.run_cell(src)
55 55 self.assertEquals(ip.user_ns['x'], 2)
56 56 self.assertEquals(ip.user_ns['y'], 3)
57
57
58 def test_multiline_string_cells(self):
59 """Code sprinkled with multiline strings should execute (GH-306)"""
60 ip = get_ipython()
61 ip.run_cell('tmp=0')
62 self.assertEquals(ip.user_ns['tmp'], 0)
63 ip.run_cell('tmp=1;"""a\nb"""\n')
64 self.assertEquals(ip.user_ns['tmp'], 1)
General Comments 0
You need to be logged in to leave comments. Login now