parent
20222ec57b
commit
216919d612
|
@ -122,7 +122,7 @@ class Config(object):
|
|||
""" same as previous, but returns conftest's path
|
||||
as well
|
||||
"""
|
||||
val, mod = self.conftest.rget_path(name, path)
|
||||
val, mod = self.conftest.rget_with_confmod(name, path)
|
||||
return val, py.path.local(mod.__file__).dirpath()
|
||||
|
||||
def initsession(self):
|
||||
|
|
|
@ -64,7 +64,7 @@ class Conftest(object):
|
|||
modules.reverse()
|
||||
return self._get(name, modules)
|
||||
|
||||
def rget_path(self, name, path=None):
|
||||
def rget_with_confmod(self, name, path=None):
|
||||
return self._rget(name, path)
|
||||
|
||||
def _get(self, name, modules):
|
||||
|
|
|
@ -68,7 +68,7 @@ class TestConftestValueAccessGlobal:
|
|||
def test_value_access_path(self):
|
||||
topdir = self.basedir.join("adir", "b")
|
||||
conftest = Conftest(topdir)
|
||||
_, mod = conftest.rget_path("a")
|
||||
_, mod = conftest.rget_with_confmod("a")
|
||||
assert py.path.local(mod.__file__).dirpath() == topdir
|
||||
|
||||
class TestConftestValueAccessInPackage(TestConftestValueAccessGlobal):
|
||||
|
|
Loading…
Reference in New Issue