]> granicus.if.org Git - python/commitdiff
Issue 22940: fixes to editline support
authorNed Deily <nad@acm.org>
Wed, 26 Nov 2014 21:02:33 +0000 (13:02 -0800)
committerNed Deily <nad@acm.org>
Wed, 26 Nov 2014 21:02:33 +0000 (13:02 -0800)
Lib/test/test_readline.py
Modules/readline.c

index 90dcdf21ee65389610e5bfef0b2fa214d15be07c..23d6194e8ecece7a7c0afecee8cb3efe771186a9 100644 (file)
@@ -43,7 +43,7 @@ class TestHistoryManipulation (unittest.TestCase):
 
         self.assertEqual(readline.get_current_history_length(), 1)
 
-    @unittest.skipUnless(hasattr(readline, "append_history"),
+    @unittest.skipUnless(hasattr(readline, "append_history_file"),
                          "append_history not available")
     def test_write_read_append(self):
         hfile = tempfile.NamedTemporaryFile(delete=False)
index 7e0282c57892a0c8702e0dd16d93fa3550a4bbd6..26dfffbfaa937db55366fb398d639e5243983c08 100644 (file)
@@ -786,8 +786,8 @@ static struct PyMethodDef readline_methods[] =
      METH_VARARGS, doc_write_history_file},
 #ifdef HAVE_RL_APPEND_HISTORY
     {"append_history_file", append_history_file,
-#endif
      METH_VARARGS, doc_append_history_file},
+#endif
     {"get_history_item", get_history_item,
      METH_VARARGS, doc_get_history_item},
     {"get_current_history_length", (PyCFunction)get_current_history_length,