[py-svn] r36608 - in py/dist/py/apigen: . testing

guido at codespeak.net guido at codespeak.net
Fri Jan 12 19:07:54 CET 2007


Author: guido
Date: Fri Jan 12 19:07:43 2007
New Revision: 36608

Modified:
   py/dist/py/apigen/htmlgen.py
   py/dist/py/apigen/style.css
   py/dist/py/apigen/testing/test_linker.py
Log:
Some style fixes, updated linker tests (oops).


Modified: py/dist/py/apigen/htmlgen.py
==============================================================================
--- py/dist/py/apigen/htmlgen.py	(original)
+++ py/dist/py/apigen/htmlgen.py	Fri Jan 12 19:07:43 2007
@@ -8,13 +8,16 @@
 raw = py.xml.raw
 
 class H(html):
-    class ClassDescription(html.div):
+    class Description(html.div):
+        style = html.Style(margin_left='10em')
+    
+    class ClassDescription(Description):
         pass
 
     class ClassDef(html.h1):
         pass
 
-    class MethodDescription(html.div):
+    class MethodDescription(Description):
         pass
 
     class MethodDef(html.h2):
@@ -27,7 +30,7 @@
         pass
 
     class Navigation(html.div):
-        pass
+        style = html.Style(min_height='99%', float='left', margin_top='1.2em')
 
     class NavigationItem(html.span):
         pass
@@ -36,7 +39,7 @@
         pass
 
     class SourceDef(html.div):
-        style = html.Style(whitespace='pre')
+        pass
 
 def get_param_htmldesc(linker, func):
     """ get the html for the parameters of a function """

Modified: py/dist/py/apigen/style.css
==============================================================================
--- py/dist/py/apigen/style.css	(original)
+++ py/dist/py/apigen/style.css	Fri Jan 12 19:07:43 2007
@@ -20,6 +20,19 @@
   display: none;
 }
 
+#logo {
+  /* float: left; */
+}
+
+#logo img {
+  border-width: 0px;
+}
+
+.project_title {
+  font-size: 2em;
+  font-weight: bold;
+}
+
 body, div, p, h1, h2, h3, h4 {
   font-family: Trebuchet MS, Verdana, Arial;
   background-color: #FFE;
@@ -40,7 +53,7 @@
   list-style-type: none;
 }
 
-a {
+.code a {
     color: blue;
     font-weight: bold;
     text-decoration: none;

Modified: py/dist/py/apigen/testing/test_linker.py
==============================================================================
--- py/dist/py/apigen/testing/test_linker.py	(original)
+++ py/dist/py/apigen/testing/test_linker.py	Fri Jan 12 19:07:43 2007
@@ -5,21 +5,19 @@
 class TestLinker(object):
     def test_one_lazy_link(self):
         linker = Linker()
-        linker.set_root('/root')
         lazyhref = linker.get_lazyhref('py.path.local')
         linker.set_link('py.path.local', 'py/path/local.html')
         href = unicode(lazyhref)
-        assert href == '/root/py/path/local.html'
+        assert href == 'py/path/local.html'
     
     def test_source_link_getrelfspath(self):
         linker = Linker()
-        linker.set_root('/root')
 
         relfspath = getrelfspath('py.path.local')
         lazyhref = linker.get_lazyhref(relfspath)
         linker.set_link(relfspath, "hello/world")
         href = unicode(lazyhref)
-        assert href == '/root/hello/world'
+        assert href == 'hello/world'
 
 # considerations for futurue use
 """
@@ -28,7 +26,7 @@
 
 def create_method_html(dotted_name, dsa, linker):
     ...
-    # <a href="<linker.root>/py/path/local.html#py.path.local.dirpath">
+    # <a href="py/path/local.html#py.path.local.dirpath">
     a = linker.make_source_link(dotted_name)
     ...
 



More information about the pytest-commit mailing list