Patchwork [5,of,9] tests: ensure demandimport test uses absolute_import

login
register
mail settings
Submitter Augie Fackler
Date Aug. 24, 2017, 2:33 p.m.
Message ID <a2b9f131501a0c1dbb83.1503585206@imladris.local>
Download mbox | patch
Permalink /patch/23297/
State Accepted
Headers show

Comments

Augie Fackler - Aug. 24, 2017, 2:33 p.m.
# HG changeset patch
# User Augie Fackler <raf@durin42.com>
# Date 1503431453 14400
#      Tue Aug 22 15:50:53 2017 -0400
# Node ID a2b9f131501a0c1dbb83ce425faa4acd50d5f8f8
# Parent  054834a8867e719f9decfe043ae58dfaa91a8812
tests: ensure demandimport test uses absolute_import

Patch

diff --git a/tests/test-check-py3-compat.t b/tests/test-check-py3-compat.t
--- a/tests/test-check-py3-compat.t
+++ b/tests/test-check-py3-compat.t
@@ -20,7 +20,6 @@ 
   contrib/python-zstandard/tests/test_module_attributes.py not using absolute_import
   contrib/python-zstandard/tests/test_train_dictionary.py not using absolute_import
   setup.py not using absolute_import
-  tests/test-demandimport.py not using absolute_import
 
 #if py3exe
   $ testrepohg files 'set:(**.py) - grep(pygments)' \
diff --git a/tests/test-demandimport.py b/tests/test-demandimport.py
--- a/tests/test-demandimport.py
+++ b/tests/test-demandimport.py
@@ -1,4 +1,4 @@ 
-from __future__ import print_function
+from __future__ import absolute_import, print_function
 
 from mercurial import demandimport
 demandimport.enable()