changeset 33991:aaa65baf460c

tests: update test-obsolete to pass our import checker
author Augie Fackler <raf@durin42.com>
date Tue, 22 Aug 2017 17:15:20 -0400
parents b4707311d982
children 492cd4bbca08
files tests/test-obsolete.t
diffstat 1 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- 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):