summaryrefslogtreecommitdiff
path: root/setuptools/tests/test_egg_info.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2015-01-02 10:07:53 -0500
committerJason R. Coombs <jaraco@jaraco.com>2015-01-02 10:07:53 -0500
commita0bfbbff64b076dab3d4c07b488043a42932bd3e (patch)
tree54009192c5c1c128b9d5a1e6b703c31f1ee91956 /setuptools/tests/test_egg_info.py
parent66ed0829c7d9e59592d0d977ac7f51e772b666f8 (diff)
downloadpython-setuptools-git-a0bfbbff64b076dab3d4c07b488043a42932bd3e.tar.gz
Rewrite paths construction as generator expression.
Diffstat (limited to 'setuptools/tests/test_egg_info.py')
-rw-r--r--setuptools/tests/test_egg_info.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/setuptools/tests/test_egg_info.py b/setuptools/tests/test_egg_info.py
index 6d7ba345..a92779d5 100644
--- a/setuptools/tests/test_egg_info.py
+++ b/setuptools/tests/test_egg_info.py
@@ -33,10 +33,12 @@ class TestEggInfo:
self._create_project()
with contexts.tempdir(prefix='setuptools-test.') as temp_dir:
os.chmod(temp_dir, stat.S_IRWXU)
- paths = {}
- for dirname in ['home', 'lib', 'scripts', 'data', 'egg-base']:
- paths[dirname] = os.path.join(temp_dir, dirname)
- os.mkdir(paths[dirname])
+ subs = 'home', 'lib', 'scripts', 'data', 'egg-base'
+ paths = dict(
+ (dirname, os.path.join(temp_dir, dirname))
+ for dirname in subs
+ )
+ list(map(os.mkdir, paths.values()))
config = os.path.join(paths['home'], '.pydistutils.cfg')
with open(config, 'w') as f:
f.write('[egg_info]\n')