fixing some release/apigen related issues
--HG-- branch : trunk
This commit is contained in:
parent
82d40724fa
commit
629fe2151c
|
@ -66,7 +66,6 @@ initpkg(__name__,
|
||||||
'test.__doc__' : ('./test/__init__.py', '__doc__'),
|
'test.__doc__' : ('./test/__init__.py', '__doc__'),
|
||||||
'test._PluginManager' : ('./test/pluginmanager.py', 'PluginManager'),
|
'test._PluginManager' : ('./test/pluginmanager.py', 'PluginManager'),
|
||||||
'test.raises' : ('./test/outcome.py', 'raises'),
|
'test.raises' : ('./test/outcome.py', 'raises'),
|
||||||
'test.deprecated_call' : ('./test/outcome.py', 'deprecated_call'),
|
|
||||||
'test.skip' : ('./test/outcome.py', 'skip'),
|
'test.skip' : ('./test/outcome.py', 'skip'),
|
||||||
'test.importorskip' : ('./test/outcome.py', 'importorskip'),
|
'test.importorskip' : ('./test/outcome.py', 'importorskip'),
|
||||||
'test.fail' : ('./test/outcome.py', 'fail'),
|
'test.fail' : ('./test/outcome.py', 'fail'),
|
||||||
|
|
|
@ -109,7 +109,7 @@ class Hooks:
|
||||||
mm = HookCall(registry, name, firstresult=firstresult)
|
mm = HookCall(registry, name, firstresult=firstresult)
|
||||||
setattr(self, name, mm)
|
setattr(self, name, mm)
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
return "<Hooks %r %r>" %(self._hookspecs, self._plugins)
|
return "<Hooks %r %r>" %(self._hookspecs, self.registry)
|
||||||
|
|
||||||
class HookCall:
|
class HookCall:
|
||||||
def __init__(self, registry, name, firstresult, extralookup=None):
|
def __init__(self, registry, name, firstresult, extralookup=None):
|
||||||
|
|
|
@ -10,6 +10,7 @@ except ImportError:
|
||||||
py.std.sys.exit()
|
py.std.sys.exit()
|
||||||
else:
|
else:
|
||||||
args = list(sys.argv[1:])
|
args = list(sys.argv[1:])
|
||||||
|
args.extend(['-p', 'apigen'])
|
||||||
argkeys = [a.split('=')[0] for a in args]
|
argkeys = [a.split('=')[0] for a in args]
|
||||||
if '--apigen' not in argkeys:
|
if '--apigen' not in argkeys:
|
||||||
args.append('--apigen')
|
args.append('--apigen')
|
||||||
|
@ -18,5 +19,5 @@ else:
|
||||||
os.path.dirname(apigen.__file__), 'tool', 'py_build', 'build.py')
|
os.path.dirname(apigen.__file__), 'tool', 'py_build', 'build.py')
|
||||||
args.append('--apigenscript=%s' % (fpath,))
|
args.append('--apigenscript=%s' % (fpath,))
|
||||||
if '--apigenpath' not in argkeys:
|
if '--apigenpath' not in argkeys:
|
||||||
args.append('--apigenpath=/tmp/pylib-api')
|
args.append('--apigenpath=api')
|
||||||
py.test.cmdline.main(args)
|
py.test.cmdline.main(args)
|
||||||
|
|
|
@ -4,6 +4,17 @@ import py
|
||||||
import sys
|
import sys
|
||||||
import inspect
|
import inspect
|
||||||
|
|
||||||
|
def test_all_resolves():
|
||||||
|
seen = py.builtin.set([py])
|
||||||
|
lastlength = None
|
||||||
|
while len(seen) != lastlength:
|
||||||
|
lastlength = len(seen)
|
||||||
|
for item in py.builtin.frozenset(seen):
|
||||||
|
for value in item.__dict__.values():
|
||||||
|
if isinstance(value, type(py.test)):
|
||||||
|
seen.add(value)
|
||||||
|
|
||||||
|
|
||||||
class TestAPI_V0_namespace_consistence:
|
class TestAPI_V0_namespace_consistence:
|
||||||
def test_path_entrypoints(self):
|
def test_path_entrypoints(self):
|
||||||
assert inspect.ismodule(py.path)
|
assert inspect.ismodule(py.path)
|
||||||
|
|
Loading…
Reference in New Issue