[meld/Python3: 51/54] test_filediff: Update for python 3 compat



commit 42f80f44d8692ca3cc23e14e254796a3ef27e122
Author: Kai Willadsen <kai willadsen gmail com>
Date:   Mon May 2 07:16:38 2016 +1000

    test_filediff: Update for python 3 compat

 test/test_filediff.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/test/test_filediff.py b/test/test_filediff.py
index d3f8aca..5124fb3 100644
--- a/test/test_filediff.py
+++ b/test/test_filediff.py
@@ -77,7 +77,7 @@ def test_filter_text(text, ignored_ranges):
 
     filediff = mock.MagicMock()
     filediff.text_filters = filters
-    filter_text = FileDiff._filter_text.__func__
+    filter_text = FileDiff._filter_text
 
     buf = Gtk.TextBuffer()
     buf.create_tag("inline")
@@ -96,7 +96,7 @@ def test_filter_text(text, ignored_ranges):
         toggles.append(it.get_offset())
     while it.forward_to_tag_toggle(tag):
         toggles.append(it.get_offset())
-    toggles = zip(toggles[::2], toggles[1::2])
+    toggles = list(zip(toggles[::2], toggles[1::2]))
 
     print("Text:", text)
     print("Toggles:", toggles)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]