[Python-checkins] r73962 - in python/trunk: .bzrignore .hgignore Lib/test/data Lib/test/test_support.py Makefile.pre.in
benjamin.peterson
python-checkins at python.org
Sun Jul 12 00:15:14 CEST 2009
Author: benjamin.peterson
Date: Sun Jul 12 00:15:13 2009
New Revision: 73962
Log:
put downloaded test support files in Lib/data instead of the cwd
Added:
python/trunk/Lib/test/data/ (props changed)
Modified:
python/trunk/ (props changed)
python/trunk/.bzrignore
python/trunk/.hgignore
python/trunk/Lib/test/test_support.py
python/trunk/Makefile.pre.in
Modified: python/trunk/.bzrignore
==============================================================================
--- python/trunk/.bzrignore (original)
+++ python/trunk/.bzrignore Sun Jul 12 00:15:13 2009
@@ -14,24 +14,7 @@
pyconfig.h
libpython*.a
python.exe
-CP936.TXT
-SHIFT_JISX0213.TXT
-JOHAB.TXT
-EUC-JP.TXT
-NormalizationTest-3.2.0.txt
-NormalizationTest.txt
-BIG5.TXT
-BIG5HKSCS-2004.TXT
-CP949.TXT
-EUC-CN.TXT
-BIG5HKSCS.TXT
-SHIFTJIS.TXT
-EUC-KR.TXT
-EUC-JISX0213.TXT
-CP932.TXT
-CP950.TXT
reflog.txt
-gb-18030-2000.xml
tags
TAGS
.gdb_history
Modified: python/trunk/.hgignore
==============================================================================
--- python/trunk/.hgignore (original)
+++ python/trunk/.hgignore Sun Jul 12 00:15:13 2009
@@ -1,24 +1,8 @@
.gdb_history
.purify
.svn
-BIG5.TXT
-BIG5HKSCS-2004.TXT
-BIG5HKSCS.TXT
-CP932.TXT
-CP936.TXT
-CP949.TXT
-CP950.TXT
-EUC-CN.TXT
-EUC-JISX0213.TXT
-EUC-JP.TXT
-EUC-KR.TXT
-JOHAB.TXT
Makefile
Makefile.pre
-NormalizationTest-3.2.0.txt
-NormalizationTest.txt
-SHIFTJIS.TXT
-SHIFT_JISX0213.TXT
TAGS
autom4te.cache
build
@@ -28,7 +12,6 @@
config.status
config.status.lineno
db_home
-gb-18030-2000.xml
platform
pyconfig.h
python
Modified: python/trunk/Lib/test/test_support.py
==============================================================================
--- python/trunk/Lib/test/test_support.py (original)
+++ python/trunk/Lib/test/test_support.py Sun Jul 12 00:15:13 2009
@@ -468,13 +468,12 @@
requires('urlfetch')
filename = urlparse.urlparse(url)[2].split('/')[-1] # '/': it's URL!
- for path in [os.path.curdir, os.path.pardir]:
- fn = os.path.join(path, filename)
- if os.path.exists(fn):
- return open(fn)
+ fn = os.path.join(os.path.dirname(__file__), "data", filename)
+ if os.path.exists(fn):
+ return open(fn)
print >> get_original_stdout(), '\tfetching %s ...' % url
- fn, _ = urllib.urlretrieve(url, filename)
+ fn, _ = urllib.urlretrieve(url, fn)
return open(fn)
Modified: python/trunk/Makefile.pre.in
==============================================================================
--- python/trunk/Makefile.pre.in (original)
+++ python/trunk/Makefile.pre.in Sun Jul 12 00:15:13 2009
@@ -1173,6 +1173,7 @@
# remove all generated files, even Makefile[.pre]
# Keep configure and Python-ast.[ch], it's possible they can't be generated
distclean: clobber
+ -rm -f Lib/test/data/*
-rm -f core Makefile Makefile.pre config.status \
Modules/Setup Modules/Setup.local Modules/Setup.config
find $(srcdir) '(' -name '*.fdc' -o -name '*~' \
More information about the Python-checkins
mailing list