##// END OF EJS Templates
skip multiline history tests on windows...
Julian Taylor -
Show More
@@ -38,10 +38,13 b' class InteractiveShellTestCase(unittest.TestCase):'
38 """Test that function does not throw on windows without
38 """Test that function does not throw on windows without
39 remove_history_item"""
39 remove_history_item"""
40 ip = get_ipython()
40 ip = get_ipython()
41 del ip.readline.remove_history_item
41 if hasattr(ip.readline, 'remove_history_item'):
42 del ip.readline.remove_history_item
42 ip._replace_rlhist_multiline(u'source', 0)
43 ip._replace_rlhist_multiline(u'source', 0)
43
44
44 @skipif(not get_ipython().has_readline, 'no readline')
45 @skipif(not get_ipython().has_readline, 'no readline')
46 @skipif(not hasattr(get_ipython().readline, 'remove_history_item'),
47 'no remove_history_item')
45 def test_replace_multiline_hist_disabled(self):
48 def test_replace_multiline_hist_disabled(self):
46 """Test that multiline replace does nothing if disabled"""
49 """Test that multiline replace does nothing if disabled"""
47 ip = get_ipython()
50 ip = get_ipython()
@@ -60,6 +63,8 b' class InteractiveShellTestCase(unittest.TestCase):'
60 self.assertEquals(hist, ghist)
63 self.assertEquals(hist, ghist)
61
64
62 @skipif(not get_ipython().has_readline, 'no readline')
65 @skipif(not get_ipython().has_readline, 'no readline')
66 @skipif(not hasattr(get_ipython().readline, 'remove_history_item'),
67 'no remove_history_item')
63 def test_replace_multiline_hist_adds(self):
68 def test_replace_multiline_hist_adds(self):
64 """Test that multiline replace function adds history"""
69 """Test that multiline replace function adds history"""
65 ip = get_ipython()
70 ip = get_ipython()
@@ -71,6 +76,8 b' class InteractiveShellTestCase(unittest.TestCase):'
71 ip.readline.get_current_history_length())
76 ip.readline.get_current_history_length())
72
77
73 @skipif(not get_ipython().has_readline, 'no readline')
78 @skipif(not get_ipython().has_readline, 'no readline')
79 @skipif(not hasattr(get_ipython().readline, 'remove_history_item'),
80 'no remove_history_item')
74 def test_replace_multiline_hist_keeps_history(self):
81 def test_replace_multiline_hist_keeps_history(self):
75 """Test that multiline replace does not delete history"""
82 """Test that multiline replace does not delete history"""
76 ip = get_ipython()
83 ip = get_ipython()
@@ -93,6 +100,8 b' class InteractiveShellTestCase(unittest.TestCase):'
93
100
94
101
95 @skipif(not get_ipython().has_readline, 'no readline')
102 @skipif(not get_ipython().has_readline, 'no readline')
103 @skipif(not hasattr(get_ipython().readline, 'remove_history_item'),
104 'no remove_history_item')
96 def test_replace_multiline_hist_replaces_twice(self):
105 def test_replace_multiline_hist_replaces_twice(self):
97 """Test that multiline entries are replaced twice"""
106 """Test that multiline entries are replaced twice"""
98 ip = get_ipython()
107 ip = get_ipython()
@@ -119,6 +128,8 b' class InteractiveShellTestCase(unittest.TestCase):'
119
128
120
129
121 @skipif(not get_ipython().has_readline, 'no readline')
130 @skipif(not get_ipython().has_readline, 'no readline')
131 @skipif(not hasattr(get_ipython().readline, 'remove_history_item'),
132 'no remove_history_item')
122 def test_replace_multiline_hist_replaces_empty_line(self):
133 def test_replace_multiline_hist_replaces_empty_line(self):
123 """Test that multiline history skips empty line cells"""
134 """Test that multiline history skips empty line cells"""
124 ip = get_ipython()
135 ip = get_ipython()
General Comments 0
You need to be logged in to leave comments. Login now