tests: enable import checker for tests/**.py files
authorYuya Nishihara <yuya@tcha.org>
Sun, 03 Apr 2016 19:38:57 +0900
changeset 28844 99a2bdad0fda
parent 28843 2c7e6f363138
child 28845 5a398627db92
tests: enable import checker for tests/**.py files Several known-bad files are excluded as they couldn't be trivially fixed. In principle, we should fix them first, however, it would have more risk to keep Py3k porting going without the test coverage. Still contrib/**.py aren't covered, which needs another round.
tests/test-check-module-imports.t
--- a/tests/test-check-module-imports.t	Tue Apr 05 23:38:00 2016 +0900
+++ b/tests/test-check-module-imports.t	Sun Apr 03 19:38:57 2016 +0900
@@ -141,6 +141,15 @@
 hidden by deduplication algorithm in the cycle detector, so fixing
 these may expose other cycles.
 
-  $ hg locate 'mercurial/**.py' 'hgext/**.py' | sed 's-\\-/-g' | python "$import_checker" -
+Known-bad files are excluded by -X as some of them would produce unstable
+outputs, which should be fixed later.
+
+  $ hg locate 'mercurial/**.py' 'hgext/**.py' 'tests/**.py' \
+  > -X tests/test-hgweb-auth.py \
+  > -X tests/hypothesishelpers.py \
+  > -X tests/test-ctxmanager.py \
+  > -X tests/test-lock.py \
+  > -X tests/test-verify-repo-operations.py \
+  > | sed 's-\\-/-g' | python "$import_checker" -
   Import cycle: hgext.largefiles.basestore -> hgext.largefiles.localstore -> hgext.largefiles.basestore
   [1]