[Checkins] SVN: z3c.layer/trunk/src/z3c/layer/ Avoid the global
Functional layer as it makes no sense with eggs.
Stefan H. Holek
stefan at epy.co.at
Thu Mar 29 05:03:41 EDT 2007
Log message for revision 73897:
Avoid the global Functional layer as it makes no sense with eggs.
Changed:
U z3c.layer/trunk/src/z3c/layer/minimal/README.txt
U z3c.layer/trunk/src/z3c/layer/minimal/tests/ftesting.zcml
U z3c.layer/trunk/src/z3c/layer/minimal/tests/test_layer.py
D z3c.layer/trunk/src/z3c/layer/minimal/z3c.layer.minimal-ftesting.zcml
U z3c.layer/trunk/src/z3c/layer/trusted/README.txt
U z3c.layer/trunk/src/z3c/layer/trusted/ftesting.zcml
U z3c.layer/trunk/src/z3c/layer/trusted/tests.py
D z3c.layer/trunk/src/z3c/layer/trusted/z3c.layer.trusted-ftesting.zcml
-=-
Modified: z3c.layer/trunk/src/z3c/layer/minimal/README.txt
===================================================================
--- z3c.layer/trunk/src/z3c/layer/minimal/README.txt 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/minimal/README.txt 2007-03-29 09:03:40 UTC (rev 73897)
@@ -81,24 +81,27 @@
<title>testing</title>
</head>
<body>
- <div align="center">
+ <div>
+ <br />
+ <br />
<h3>
- The page that you are trying to access is not available
+ The page you are trying to access is not available
</h3>
<br />
- <b>Please note the following:</b>
+ <b>
+ Please try the following:
+ </b>
<br />
<ol>
- <li>You might have misspelled the url </li>
<li>
- You might be trying to access a non-existing page
+ Make sure that the Web site address is spelled correctly.
</li>
+ <li>
+ <a href="javascript:history.back(1);">
+ Go back and try another URL.
+ </a>
+ </li>
</ol>
- <a href="javascript:history.back(1);">
- <span>
- Go back and try another URL.
- </span>
- </a>
</div>
</body>
</html>
@@ -116,7 +119,7 @@
<title>testing</title>
</head>
<body>
- <div align="center">
+ <div>
<div>simply user error</div>
</div>
</body>
@@ -135,14 +138,14 @@
<title>testing</title>
</head>
<body>
- <div align="center">
- <h3>A system error occours.</h3>
+ <div>
<br />
- <b>Contact the administrator.</b>
+ <br />
+ <h3>A system error occurred</h3>
+ <br />
+ <b>Please contact the administrator.</b>
<a href="javascript:history.back(1);">
- <span>
- Go back and try another URL.
- </span>
+ Go back and try another URL.
</a>
</div>
</body>
Modified: z3c.layer/trunk/src/z3c/layer/minimal/tests/ftesting.zcml
===================================================================
--- z3c.layer/trunk/src/z3c/layer/minimal/tests/ftesting.zcml 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/minimal/tests/ftesting.zcml 2007-03-29 09:03:40 UTC (rev 73897)
@@ -1,7 +1,63 @@
-<configure
- xmlns="http://namespaces.zope.org/zope"
- xmlns:browser="http://namespaces.zope.org/browser">
+<configure xmlns="http://namespaces.zope.org/zope"
+ xmlns:meta="http://namespaces.zope.org/meta"
+ xmlns:browser="http://namespaces.zope.org/browser"
+ i18n_domain="zope"
+ package="z3c.layer.minimal.tests">
+ <include package="zope.app.zcmlfiles" />
+
+ <include package="zope.app.securitypolicy" file="meta.zcml" />
+ <include package="zope.app.authentication" />
+ <securityPolicy
+ component="zope.app.securitypolicy.zopepolicy.ZopeSecurityPolicy" />
+
+ <include package="zope.app.securitypolicy" />
+
+ <role id="zope.Anonymous" title="Everybody"
+ description="All users have this role implicitly" />
+
+ <role id="zope.Manager" title="Site Manager" />
+
+ <principal
+ id="zope.manager"
+ title="Administrator"
+ login="mgr"
+ password="mgrpw" />
+
+ <grant
+ role="zope.Manager"
+ principal="zope.manager"
+ />
+
+ <unauthenticatedPrincipal
+ id="zope.anybody"
+ title="Unauthenticated User" />
+
+ <unauthenticatedGroup
+ id="zope.Anybody"
+ title="Unauthenticated Users"
+ />
+
+ <authenticatedGroup
+ id="zope.Authenticated"
+ title="Authenticated Users"
+ />
+
+ <everybodyGroup
+ id="zope.Everybody"
+ title="All Users"
+ />
+
+ <grantAll role="zope.Manager" />
+
+ <include package="zope.app.form.browser" />
+ <include package="zope.app.http.exception" />
+ <include package="zope.app.publication" />
+ <include package="zope.app.publisher.browser" />
+ <include package="zope.traversing" />
+ <include package="zope.traversing.browser" />
+ <include package="z3c.layer.minimal" />
+
<interface
interface="z3c.layer.minimal.tests.IMinimalTestingSkin"
type="zope.publisher.interfaces.browser.IBrowserSkinType"
Modified: z3c.layer/trunk/src/z3c/layer/minimal/tests/test_layer.py
===================================================================
--- z3c.layer/trunk/src/z3c/layer/minimal/tests/test_layer.py 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/minimal/tests/test_layer.py 2007-03-29 09:03:40 UTC (rev 73897)
@@ -16,13 +16,19 @@
"""
import unittest
+from zope.testing import doctest
from zope.app.testing import functional
+functional.defineLayer('TestLayer', 'ftesting.zcml')
+
def test_suite():
- suite = unittest.TestSuite((
- functional.FunctionalDocFileSuite('../README.txt'),
- ))
+ suite = unittest.TestSuite()
+
+ s = functional.FunctionalDocFileSuite('../README.txt')
+ s.layer = TestLayer
+ suite.addTest(s)
+
return suite
if __name__ == '__main__':
Deleted: z3c.layer/trunk/src/z3c/layer/minimal/z3c.layer.minimal-ftesting.zcml
===================================================================
--- z3c.layer/trunk/src/z3c/layer/minimal/z3c.layer.minimal-ftesting.zcml 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/minimal/z3c.layer.minimal-ftesting.zcml 2007-03-29 09:03:40 UTC (rev 73897)
@@ -1 +0,0 @@
-<include package="z3c.layer.minimal.tests" file="ftesting.zcml" />
Modified: z3c.layer/trunk/src/z3c/layer/trusted/README.txt
===================================================================
--- z3c.layer/trunk/src/z3c/layer/trusted/README.txt 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/trusted/README.txt 2007-03-29 09:03:40 UTC (rev 73897)
@@ -66,24 +66,27 @@
<title>testing</title>
</head>
<body>
- <div align="center">
+ <div>
+ <br />
+ <br />
<h3>
- The page that you are trying to access is not available
+ The page you are trying to access is not available
</h3>
<br />
- <b>Please note the following:</b>
+ <b>
+ Please try the following:
+ </b>
<br />
<ol>
- <li>You might have misspelled the url </li>
<li>
- You might be trying to access a non-existing page
+ Make sure that the Web site address is spelled correctly.
</li>
+ <li>
+ <a href="javascript:history.back(1);">
+ Go back and try another URL.
+ </a>
+ </li>
</ol>
- <a href="javascript:history.back(1);">
- <span>
- Go back and try another URL.
- </span>
- </a>
</div>
</body>
</html>
@@ -101,7 +104,7 @@
<title>testing</title>
</head>
<body>
- <div align="center">
+ <div>
<div>simply user error</div>
</div>
</body>
@@ -120,14 +123,14 @@
<title>testing</title>
</head>
<body>
- <div align="center">
- <h3>A system error occours.</h3>
+ <div>
<br />
- <b>Contact the administrator.</b>
+ <br />
+ <h3>A system error occurred</h3>
+ <br />
+ <b>Please contact the administrator.</b>
<a href="javascript:history.back(1);">
- <span>
- Go back and try another URL.
- </span>
+ Go back and try another URL.
</a>
</div>
</body>
Modified: z3c.layer/trunk/src/z3c/layer/trusted/ftesting.zcml
===================================================================
--- z3c.layer/trunk/src/z3c/layer/trusted/ftesting.zcml 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/trusted/ftesting.zcml 2007-03-29 09:03:40 UTC (rev 73897)
@@ -1,7 +1,13 @@
<configure
xmlns="http://namespaces.zope.org/zope"
- xmlns:browser="http://namespaces.zope.org/browser">
+ xmlns:meta="http://namespaces.zope.org/meta"
+ xmlns:browser="http://namespaces.zope.org/browser"
+ i18n_domain="zope"
+ package="z3c.layer.trusted">
+ <include package="z3c.layer.minimal.tests" file="ftesting.zcml"/>
+ <include package="z3c.layer.trusted" />
+
<interface
interface="z3c.layer.trusted.tests.ITrustedTestingSkin"
type="zope.publisher.interfaces.browser.IBrowserSkinType"
Modified: z3c.layer/trunk/src/z3c/layer/trusted/tests.py
===================================================================
--- z3c.layer/trunk/src/z3c/layer/trusted/tests.py 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/trusted/tests.py 2007-03-29 09:03:40 UTC (rev 73897)
@@ -20,7 +20,9 @@
from z3c.layer import trusted
+layer = functional.defineLayer('TestLayer', 'ftesting.zcml')
+
class ITrustedTestingSkin(trusted.ITrustedBrowserLayer):
"""The ITrustedBrowserLayer testing skin."""
@@ -30,10 +32,13 @@
def test_suite():
- suite = unittest.TestSuite((
- functional.FunctionalDocFileSuite('README.txt',
- globs={'getRootFolder': getRootFolder}),
- ))
+ suite = unittest.TestSuite()
+
+ s = functional.FunctionalDocFileSuite('README.txt',
+ globs={'getRootFolder': getRootFolder})
+ s.layer = TestLayer
+ suite.addTest(s)
+
return suite
if __name__ == '__main__':
Deleted: z3c.layer/trunk/src/z3c/layer/trusted/z3c.layer.trusted-ftesting.zcml
===================================================================
--- z3c.layer/trunk/src/z3c/layer/trusted/z3c.layer.trusted-ftesting.zcml 2007-03-29 08:33:43 UTC (rev 73896)
+++ z3c.layer/trunk/src/z3c/layer/trusted/z3c.layer.trusted-ftesting.zcml 2007-03-29 09:03:40 UTC (rev 73897)
@@ -1 +0,0 @@
-<include package="z3c.layer.trusted" file="ftesting.zcml" />
More information about the Checkins
mailing list