fix import issue

--HG--
branch : trunk
This commit is contained in:
holger krekel 2009-04-28 23:49:03 +02:00
parent 91c78274f5
commit 170e48d946
1 changed files with 4 additions and 0 deletions

View File

@ -3,6 +3,7 @@ pytes plugin for easing testing of pytest runs themselves.
"""
import py
import os
import inspect
from py.__.test import runner
from py.__.test.config import Config as pytestConfig
@ -222,6 +223,9 @@ class TmpTestdir:
def popen(self, cmdargs, stdout, stderr, **kw):
if not hasattr(py.std, 'subprocess'):
py.test.skip("no subprocess module")
env = os.environ.copy()
env['PYTHONPATH'] = "%s:%s" % (os.getcwd(), env['PYTHONPATH'])
kw['env'] = env
return py.std.subprocess.Popen(cmdargs, stdout=stdout, stderr=stderr, **kw)
def run(self, *cmdargs):