[Checkins] SVN: zc.security/trunk/ - make this project a buildout
Benji York
benji at zope.com
Thu Mar 27 13:52:53 EDT 2008
Log message for revision 84972:
- make this project a buildout
- minor code cleanup (whitespace mostly)
- bump version to 4.2.0dev
Changed:
_U zc.security/trunk/
A zc.security/trunk/buildout.cfg
U zc.security/trunk/setup.py
U zc.security/trunk/src/zc/security/search.py
U zc.security/trunk/src/zc/security/tests.py
-=-
Property changes on: zc.security/trunk
___________________________________________________________________
Name: svn:ignore
+ develop-eggs
eggs
bin
parts
Added: zc.security/trunk/buildout.cfg
===================================================================
--- zc.security/trunk/buildout.cfg (rev 0)
+++ zc.security/trunk/buildout.cfg 2008-03-27 17:52:53 UTC (rev 84972)
@@ -0,0 +1,20 @@
+[buildout]
+develop = .
+parts = test interpreter
+find-links = http://pypi.python.org/simple
+extends = http://download.zope.org/zope3.4/versions.cfg
+versions = versions
+
+[versions]
+# make sure this buildout's version gets used, not the one specified in the KGS
+zc.security =
+
+[test]
+recipe = zc.recipe.testrunner
+eggs = zc.security
+defaults = '--tests-pattern tests --exit-with-status -1'.split()
+
+[interpreter]
+recipe = zc.recipe.egg
+eggs = zc.security
+interpreter = py
Modified: zc.security/trunk/setup.py
===================================================================
--- zc.security/trunk/setup.py 2008-03-27 17:35:53 UTC (rev 84971)
+++ zc.security/trunk/setup.py 2008-03-27 17:52:53 UTC (rev 84972)
@@ -1,31 +1,31 @@
from setuptools import setup, find_packages
setup(
- name = "zc.security",
- version = "4.1dev",
- author = "Zope Corporation",
- author_email = "zope3-dev at zope.org",
- description = "Principal-searching UI for Zope 3 Pluggable Authentication",
- license = "ZPL 2.1",
- keywords = "zope3 security",
+ name = 'zc.security',
+ version = '4.2.0dev',
+ author = 'Zope Corporation',
+ author_email = 'zope3-dev at zope.org',
+ description = 'Principal-searching UI for Zope 3 Pluggable Authentication',
+ license = 'ZPL 2.1',
+ keywords = 'zope3 security',
url='http://svn.zope.org/zc.sharing',
classifiers = [
- 'Development Status :: 3 - Alpha',
- "License :: OSI Approved :: Zope Public License",
- "Framework :: Zope :: UI",
+ 'License :: OSI Approved :: Zope Public License',
+ 'Framework :: Zope :: UI',
],
-
+
packages = find_packages('src'),
include_package_data = True,
- package_dir = {'':'src'},
+ package_dir = {'': 'src'},
namespace_packages = ['zc'],
install_requires = [
+ 'setuptools',
+ 'zope.app.authentication',
+ 'zope.app.component',
+ 'zope.app.security',
+ 'zope.component',
+ 'zope.interface',
+ 'zope.security',
'zope.testing',
- 'setuptools',
- # XXX leaving out most of the zope 3 dependencies for now,
- # since Zope 3 hasn't been packages yet.
],
- dependency_links = ['http://download.zope.org/distribution/'],
)
-
-
Modified: zc.security/trunk/src/zc/security/search.py
===================================================================
--- zc.security/trunk/src/zc/security/search.py 2008-03-27 17:35:53 UTC (rev 84971)
+++ zc.security/trunk/src/zc/security/search.py 2008-03-27 17:52:53 UTC (rev 84972)
@@ -17,19 +17,20 @@
$Id$
"""
-import zope.component
-import zope.interface
+from zc.security import interfaces
+from zope.app.component import queryNextUtility
+from zope.app.security import principalregistry
+from zope.app.security.interfaces import IAuthentication
+from zope.app.security.interfaces import PrincipalLookupError
from zope.security.interfaces import IGroup
-import zope.app.authentication.interfaces
import zope.app.authentication.authentication
import zope.app.authentication.groupfolder
+import zope.app.authentication.interfaces
import zope.app.authentication.principalfolder
-from zope.app.security import principalregistry
-from zope.app.security.interfaces import IAuthentication
-from zope.app.security.interfaces import PrincipalLookupError
-from zope.app.component import queryNextUtility
-from zc.security import interfaces
+import zope.component
+import zope.interface
+
class PASimpleSearch:
zope.component.adapts(
@@ -72,7 +73,7 @@
sz = size + start - n
if sz <= 0:
return
-
+
search = getattr(searcher, self.meth)
for principal_id in search(filter, 0, sz):
if n >= start:
@@ -94,7 +95,7 @@
searchUsers = PASimpleSearch.searchPrincipals
class GroupFolderSimpleGroupSearch:
-
+
def __init__(self, context):
self.context = context
@@ -109,7 +110,7 @@
zope.component.adapts(
zope.app.authentication.principalfolder.PrincipalFolder)
zope.interface.implements(interfaces.ISimpleUserSearch)
-
+
def __init__(self, context):
self.context = context
@@ -120,7 +121,7 @@
zope.component.adapts(principalregistry.PrincipalRegistry)
zope.interface.implements(interfaces.ISimpleUserSearch)
-
+
def __init__(self, context):
self.context = context
Modified: zc.security/trunk/src/zc/security/tests.py
===================================================================
--- zc.security/trunk/src/zc/security/tests.py 2008-03-27 17:35:53 UTC (rev 84971)
+++ zc.security/trunk/src/zc/security/tests.py 2008-03-27 17:52:53 UTC (rev 84972)
@@ -29,7 +29,3 @@
optionflags=doctest.NORMALIZE_WHITESPACE+doctest.ELLIPSIS,
),
))
-
-if __name__ == '__main__':
- unittest.main(defaultTest='test_suite')
-
More information about the Checkins
mailing list