tests: update test-obsolete to pass our import checker
authorAugie Fackler <raf@durin42.com>
Tue, 22 Aug 2017 17:15:20 -0400
changeset 33991 aaa65baf460c
parent 33990 b4707311d982
child 33992 492cd4bbca08
tests: update test-obsolete to pass our import checker
tests/test-obsolete.t
--- a/tests/test-obsolete.t	Tue Aug 22 17:15:14 2017 -0400
+++ b/tests/test-obsolete.t	Tue Aug 22 17:15:20 2017 -0400
@@ -1241,8 +1241,14 @@
 bookmarks change
   $ cd ..
   $ cat >$TESTTMP/test_extension.py  << EOF
+  > from __future__ import absolute_import, print_function
   > import weakref
-  > from mercurial import cmdutil, extensions, bookmarks, repoview
+  > from mercurial import (
+  >   bookmarks,
+  >   cmdutil,
+  >   extensions,
+  >   repoview,
+  > )
   > def _bookmarkchanged(orig, bkmstoreinst, *args, **kwargs):
   >  reporef = weakref.ref(bkmstoreinst._repo)
   >  def trhook(tr):
@@ -1250,7 +1256,7 @@
   >   hidden1 = repoview.computehidden(repo)
   >   hidden = repoview.filterrevs(repo, 'visible')
   >   if sorted(hidden1) != sorted(hidden):
-  >     print "cache inconsistency"
+  >     print("cache inconsistency")
   >  bkmstoreinst._repo.currenttransaction().addpostclose('test_extension', trhook)
   >  orig(bkmstoreinst, *args, **kwargs)
   > def extsetup(ui):