[py-svn] r62188 - py/branch/pytestplugin/py/doc
hpk at codespeak.net
hpk at codespeak.net
Thu Feb 26 15:18:26 CET 2009
Author: hpk
Date: Thu Feb 26 15:18:24 2009
New Revision: 62188
Modified:
py/branch/pytestplugin/py/doc/confrest.py
py/branch/pytestplugin/py/doc/conftest.py
Log:
adjustments before factoring out ReST as a plugin
Modified: py/branch/pytestplugin/py/doc/confrest.py
==============================================================================
--- py/branch/pytestplugin/py/doc/confrest.py (original)
+++ py/branch/pytestplugin/py/doc/confrest.py Thu Feb 26 15:18:24 2009
@@ -3,7 +3,6 @@
from py.__.misc.difftime import worded_time
from py.__.apigen.linker import relpath
-mydir = py.magic.autopath().dirpath()
html = py.xml.html
@@ -107,6 +106,7 @@
class Project:
+ mydir = py.magic.autopath().dirpath()
title = "py lib"
prefix_title = "" # we have a logo already containing "py lib"
encoding = 'latin1'
@@ -119,7 +119,7 @@
def __init__(self, sourcepath=None):
if sourcepath is None:
- sourcepath = mydir
+ sourcepath = self.mydir
self.setpath(sourcepath)
def setpath(self, sourcepath, docpath=None,
Modified: py/branch/pytestplugin/py/doc/conftest.py
==============================================================================
--- py/branch/pytestplugin/py/doc/conftest.py (original)
+++ py/branch/pytestplugin/py/doc/conftest.py Thu Feb 26 15:18:24 2009
@@ -23,15 +23,10 @@
ConftestPlugin = RestDocPlugin
def get_apigenpath():
- path = os.environ.get('DOCPATH')
- if path is None:
- return mydir
- else:
- return py.path.local().join(path, abs=True)
path = os.environ.get('APIGENPATH')
if path is None:
- path = "apigen"
- return pypkgdir.join(path, abs=True)
+ path = get_docpath().join("apigen")
+ return py.path.local(path)
def get_docpath():
path = os.environ.get('DOCPATH')
More information about the pytest-commit
mailing list