fix typos in converting test_oldmagic
--HG-- branch : trunk
This commit is contained in:
parent
8a6a3183ae
commit
9af223e6cb
|
@ -100,12 +100,12 @@ class Testautopath:
|
||||||
d = {'__file__' : str(testpath)}
|
d = {'__file__' : str(testpath)}
|
||||||
oldsyspath = sys.path[:]
|
oldsyspath = sys.path[:]
|
||||||
try:
|
try:
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
conf = d['autopath']
|
conf = d['autopath']
|
||||||
assert conf.dirpath() == self.initdir2
|
assert conf.dirpath() == self.initdir2
|
||||||
assert conf.pkgdir == self.initdir
|
assert conf.pkgdir == self.initdir
|
||||||
assert str(self.root) in sys.path
|
assert str(self.root) in sys.path
|
||||||
py.test.exec_(self.getauto in d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
assert conf is not d['autopath']
|
assert conf is not d['autopath']
|
||||||
finally:
|
finally:
|
||||||
sys.path[:] = oldsyspath
|
sys.path[:] = oldsyspath
|
||||||
|
@ -116,12 +116,12 @@ class Testautopath:
|
||||||
d = {'__file__' : str(testpath)}
|
d = {'__file__' : str(testpath)}
|
||||||
oldsyspath = sys.path[:]
|
oldsyspath = sys.path[:]
|
||||||
try:
|
try:
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
conf = d['autopath']
|
conf = d['autopath']
|
||||||
assert conf == self.initdir2.join('autoconfiguretest.py')
|
assert conf == self.initdir2.join('autoconfiguretest.py')
|
||||||
assert conf.pkgdir == self.initdir
|
assert conf.pkgdir == self.initdir
|
||||||
assert str(self.root) in sys.path
|
assert str(self.root) in sys.path
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
assert conf is not d['autopath']
|
assert conf is not d['autopath']
|
||||||
finally:
|
finally:
|
||||||
sys.path[:] = oldsyspath
|
sys.path[:] = oldsyspath
|
||||||
|
@ -131,13 +131,13 @@ class Testautopath:
|
||||||
d = {'__file__' : str(testpath)}
|
d = {'__file__' : str(testpath)}
|
||||||
oldsyspath = sys.path[:]
|
oldsyspath = sys.path[:]
|
||||||
try:
|
try:
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
conf = d['autopath']
|
conf = d['autopath']
|
||||||
assert conf.dirpath() == self.root
|
assert conf.dirpath() == self.root
|
||||||
assert conf.pkgdir == self.root
|
assert conf.pkgdir == self.root
|
||||||
syspath = sys.path[:]
|
syspath = sys.path[:]
|
||||||
assert str(self.root) in syspath
|
assert str(self.root) in syspath
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
assert conf is not d['autopath']
|
assert conf is not d['autopath']
|
||||||
finally:
|
finally:
|
||||||
sys.path[:] = oldsyspath
|
sys.path[:] = oldsyspath
|
||||||
|
@ -149,7 +149,7 @@ class Testautopath:
|
||||||
oldsyspath = sys.path[:]
|
oldsyspath = sys.path[:]
|
||||||
try:
|
try:
|
||||||
d = {}
|
d = {}
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
conf = d['autopath']
|
conf = d['autopath']
|
||||||
assert conf.dirpath() == self.initdir2
|
assert conf.dirpath() == self.initdir2
|
||||||
assert conf.pkgdir == self.initdir
|
assert conf.pkgdir == self.initdir
|
||||||
|
@ -167,7 +167,7 @@ class Testautopath:
|
||||||
try:
|
try:
|
||||||
py.test.raises(ValueError,'''
|
py.test.raises(ValueError,'''
|
||||||
d = {}
|
d = {}
|
||||||
py.test.exec_(self.getauto, d)
|
py.builtin.exec_(self.getauto, d)
|
||||||
''')
|
''')
|
||||||
finally:
|
finally:
|
||||||
sys.path[:] = oldsyspath
|
sys.path[:] = oldsyspath
|
||||||
|
|
Loading…
Reference in New Issue