Mercurial > hg
comparison tests/test-module-imports.t @ 23894:f388ceae2250
test-module-imports: use test-repo requirement
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Fri, 16 Jan 2015 16:25:30 -0800 |
parents | c63a09b6b337 |
children | 01b39e821d00 |
comparison
equal
deleted
inserted
replaced
23893:f21a0d6d6efd | 23894:f388ceae2250 |
---|---|
1 #require test-repo | |
2 | |
1 This code uses the ast module, which was new in 2.6, so we'll skip | 3 This code uses the ast module, which was new in 2.6, so we'll skip |
2 this test on anything earlier. | 4 this test on anything earlier. |
3 $ $PYTHON -c 'import sys ; assert sys.version_info >= (2, 6)' || exit 80 | 5 $ $PYTHON -c 'import sys ; assert sys.version_info >= (2, 6)' || exit 80 |
4 | 6 |
5 $ import_checker="$TESTDIR"/../contrib/import-checker.py | 7 $ import_checker="$TESTDIR"/../contrib/import-checker.py |
8 | |
6 Run the doctests from the import checker, and make sure | 9 Run the doctests from the import checker, and make sure |
7 it's working correctly. | 10 it's working correctly. |
8 $ TERM=dumb | 11 $ TERM=dumb |
9 $ export TERM | 12 $ export TERM |
10 $ python -m doctest $import_checker | 13 $ python -m doctest $import_checker |
11 | 14 |
12 $ cd "$TESTDIR"/.. | 15 $ cd "$TESTDIR"/.. |
13 $ if hg identify -q > /dev/null 2>&1; then : | |
14 > else | |
15 > echo "skipped: not a Mercurial working dir" >&2 | |
16 > exit 80 | |
17 > fi | |
18 | 16 |
19 There are a handful of cases here that require renaming a module so it | 17 There are a handful of cases here that require renaming a module so it |
20 doesn't overlap with a stdlib module name. There are also some cycles | 18 doesn't overlap with a stdlib module name. There are also some cycles |
21 here that we should still endeavor to fix, and some cycles will be | 19 here that we should still endeavor to fix, and some cycles will be |
22 hidden by deduplication algorithm in the cycle detector, so fixing | 20 hidden by deduplication algorithm in the cycle detector, so fixing |