Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
1bcfaa59
Commit
1bcfaa59
authored
Nov 21, 2006
by
Stefan H. Holek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Switched to Z3 interfaces, mainly because people tell me they
"don't want to see Z2 interfaces anymore".
parent
71f1dd42
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
42 additions
and
27 deletions
+42
-27
lib/python/Testing/ZopeTestCase/PortalTestCase.py
lib/python/Testing/ZopeTestCase/PortalTestCase.py
+3
-3
lib/python/Testing/ZopeTestCase/ZopeTestCase.py
lib/python/Testing/ZopeTestCase/ZopeTestCase.py
+2
-5
lib/python/Testing/ZopeTestCase/base.py
lib/python/Testing/ZopeTestCase/base.py
+2
-2
lib/python/Testing/ZopeTestCase/doc/API.stx
lib/python/Testing/ZopeTestCase/doc/API.stx
+22
-11
lib/python/Testing/ZopeTestCase/doc/CHANGES.txt
lib/python/Testing/ZopeTestCase/doc/CHANGES.txt
+3
-0
lib/python/Testing/ZopeTestCase/doc/VERSION.txt
lib/python/Testing/ZopeTestCase/doc/VERSION.txt
+1
-1
lib/python/Testing/ZopeTestCase/functional.py
lib/python/Testing/ZopeTestCase/functional.py
+3
-1
lib/python/Testing/ZopeTestCase/interfaces.py
lib/python/Testing/ZopeTestCase/interfaces.py
+1
-1
lib/python/Testing/ZopeTestCase/profiler.py
lib/python/Testing/ZopeTestCase/profiler.py
+3
-1
lib/python/Testing/ZopeTestCase/testInterfaces.py
lib/python/Testing/ZopeTestCase/testInterfaces.py
+2
-2
No files found.
lib/python/Testing/ZopeTestCase/PortalTestCase.py
View file @
1bcfaa59
...
@@ -31,6 +31,7 @@ import base
...
@@ -31,6 +31,7 @@ import base
import
interfaces
import
interfaces
import
utils
import
utils
from
zope.interface
import
implements
from
AccessControl
import
getSecurityManager
from
AccessControl
import
getSecurityManager
from
AccessControl.SecurityManagement
import
newSecurityManager
from
AccessControl.SecurityManagement
import
newSecurityManager
from
AccessControl.SecurityManagement
import
noSecurityManager
from
AccessControl.SecurityManagement
import
noSecurityManager
...
@@ -44,9 +45,8 @@ from ZopeTestCase import user_password
...
@@ -44,9 +45,8 @@ from ZopeTestCase import user_password
class
PortalTestCase
(
base
.
TestCase
):
class
PortalTestCase
(
base
.
TestCase
):
'''Base test case for testing CMF-style portals'''
'''Base test case for testing CMF-style portals'''
__implements__
=
(
interfaces
.
IPortalTestCase
,
implements
(
interfaces
.
IPortalTestCase
,
interfaces
.
IPortalSecurity
,
interfaces
.
IPortalSecurity
)
base
.
TestCase
.
__implements__
)
_configure_portal
=
1
_configure_portal
=
1
...
...
lib/python/Testing/ZopeTestCase/ZopeTestCase.py
View file @
1bcfaa59
...
@@ -30,6 +30,7 @@ import interfaces
...
@@ -30,6 +30,7 @@ import interfaces
import
utils
import
utils
import
connections
import
connections
from
zope.interface
import
implements
from
AccessControl
import
getSecurityManager
from
AccessControl
import
getSecurityManager
from
AccessControl.SecurityManagement
import
newSecurityManager
from
AccessControl.SecurityManagement
import
newSecurityManager
from
AccessControl.SecurityManagement
import
noSecurityManager
from
AccessControl.SecurityManagement
import
noSecurityManager
...
@@ -46,8 +47,7 @@ standard_permissions = [access_contents_information, view]
...
@@ -46,8 +47,7 @@ standard_permissions = [access_contents_information, view]
class
ZopeTestCase
(
base
.
TestCase
):
class
ZopeTestCase
(
base
.
TestCase
):
'''Base test case for Zope testing'''
'''Base test case for Zope testing'''
__implements__
=
(
interfaces
.
IZopeSecurity
,
implements
(
interfaces
.
IZopeSecurity
)
base
.
TestCase
.
__implements__
)
_setup_fixture
=
1
_setup_fixture
=
1
...
@@ -120,9 +120,6 @@ class FunctionalTestCase(functional.Functional, ZopeTestCase):
...
@@ -120,9 +120,6 @@ class FunctionalTestCase(functional.Functional, ZopeTestCase):
to turn it into a functional test case.
to turn it into a functional test case.
'''
'''
__implements__
=
(
functional
.
Functional
.
__implements__
,
ZopeTestCase
.
__implements__
)
from
base
import
app
from
base
import
app
from
base
import
close
from
base
import
close
...
...
lib/python/Testing/ZopeTestCase/base.py
View file @
1bcfaa59
...
@@ -23,6 +23,7 @@ import utils
...
@@ -23,6 +23,7 @@ import utils
import
interfaces
import
interfaces
import
connections
import
connections
from
zope.interface
import
implements
from
AccessControl.SecurityManagement
import
noSecurityManager
from
AccessControl.SecurityManagement
import
noSecurityManager
...
@@ -44,8 +45,7 @@ class TestCase(profiler.Profiled, unittest.TestCase, object):
...
@@ -44,8 +45,7 @@ class TestCase(profiler.Profiled, unittest.TestCase, object):
'''Base test case for Zope testing
'''Base test case for Zope testing
'''
'''
__implements__
=
(
interfaces
.
IZopeTestCase
,
implements
(
interfaces
.
IZopeTestCase
)
profiler
.
Profiled
.
__implements__
)
def
afterSetUp
(
self
):
def
afterSetUp
(
self
):
'''Called after setUp() has completed. This is
'''Called after setUp() has completed. This is
...
...
lib/python/Testing/ZopeTestCase/doc/API.stx
View file @
1bcfaa59
...
@@ -122,8 +122,9 @@ Class TestCase
...
@@ -122,8 +122,9 @@ Class TestCase
Base test case for Zope testing
Base test case for Zope testing
(derived from unittest.TestCase)
(derived from unittest.TestCase)
__implements__ = (IZopeTestCase,
Interfaces
Profiled.__implements__)
implements(IZopeTestCase)
Methods
Methods
...
@@ -168,8 +169,9 @@ Class ZopeTestCase
...
@@ -168,8 +169,9 @@ Class ZopeTestCase
Base test case for Zope testing
Base test case for Zope testing
(derived from base.TestCase)
(derived from base.TestCase)
__implements__ = (IZopeSecurity,
Interfaces
TestCase.__implements__)
implements(IZopeSecurity)
Methods
Methods
...
@@ -188,8 +190,9 @@ Class FunctionalTestCase
...
@@ -188,8 +190,9 @@ Class FunctionalTestCase
Convenience class for functional unit testing
Convenience class for functional unit testing
(derived from Functional and ZopeTestCase)
(derived from Functional and ZopeTestCase)
__implements__ = (Functional.__implements__,
Interfaces
ZopeTestCase.__implements__)
*See base classes*
Methods
Methods
...
@@ -220,9 +223,9 @@ Class PortalTestCase
...
@@ -220,9 +223,9 @@ Class PortalTestCase
Base test case for CMF testing
Base test case for CMF testing
(derived from base.TestCase)
(derived from base.TestCase)
__implements__ = (IPortalTestCase,
Interfaces
IPortalSecurity,
TestCase.__implements__
)
implements(IPortalTestCase, IPortalSecurity
)
Methods
Methods
...
@@ -262,7 +265,9 @@ Class Profiled
...
@@ -262,7 +265,9 @@ Class Profiled
Profiling support mix-in for xTestCases
Profiling support mix-in for xTestCases
__implements__ = (IProfiled,)
Interfaces
implements(IProfiled)
Methods
Methods
...
@@ -284,6 +289,10 @@ Class Sandboxed
...
@@ -284,6 +289,10 @@ Class Sandboxed
Sandbox support mix-in for xTestCases
Sandbox support mix-in for xTestCases
Interfaces
*No interfaces*
Methods
Methods
*No public methods*
*No public methods*
...
@@ -304,7 +313,9 @@ Class Functional
...
@@ -304,7 +313,9 @@ Class Functional
Functional testing mix-in for xTestCases
Functional testing mix-in for xTestCases
__implements__ = (IFunctional,)
Interfaces
implements(IFunctional)
Methods
Methods
...
...
lib/python/Testing/ZopeTestCase/doc/CHANGES.txt
View file @
1bcfaa59
0.9.10 (Zope 2.11 edition)
- Switched to Zope3 interfaces.
0.9.9 (Zope 2.11 edition)
0.9.9 (Zope 2.11 edition)
- transaction.commit(1) is deprecated in favor of transaction.savepoint(1).
- transaction.commit(1) is deprecated in favor of transaction.savepoint(1).
- Don't break if Python distros ship without profile support (Debian, Ubuntu).
- Don't break if Python distros ship without profile support (Debian, Ubuntu).
...
...
lib/python/Testing/ZopeTestCase/doc/VERSION.txt
View file @
1bcfaa59
ZopeTestCase 0.9.
9
ZopeTestCase 0.9.
10
lib/python/Testing/ZopeTestCase/functional.py
View file @
1bcfaa59
...
@@ -22,6 +22,8 @@ import transaction
...
@@ -22,6 +22,8 @@ import transaction
import
sandbox
import
sandbox
import
interfaces
import
interfaces
from
zope.interface
import
implements
class
Functional
(
sandbox
.
Sandboxed
):
class
Functional
(
sandbox
.
Sandboxed
):
'''Derive from this class and an xTestCase to get functional
'''Derive from this class and an xTestCase to get functional
...
@@ -31,7 +33,7 @@ class Functional(sandbox.Sandboxed):
...
@@ -31,7 +33,7 @@ class Functional(sandbox.Sandboxed):
...
...
'''
'''
__implements__
=
(
interfaces
.
IFunctional
,
)
implements
(
interfaces
.
IFunctional
)
def
publish
(
self
,
path
,
basic
=
None
,
env
=
None
,
extra
=
None
,
def
publish
(
self
,
path
,
basic
=
None
,
env
=
None
,
extra
=
None
,
request_method
=
'GET'
,
stdin
=
None
,
handle_errors
=
True
):
request_method
=
'GET'
,
stdin
=
None
,
handle_errors
=
True
):
...
...
lib/python/Testing/ZopeTestCase/interfaces.py
View file @
1bcfaa59
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
$Id$
$Id$
"""
"""
from
I
nterface
import
Interface
from
zope.i
nterface
import
Interface
class
IZopeTestCase
(
Interface
):
class
IZopeTestCase
(
Interface
):
...
...
lib/python/Testing/ZopeTestCase/profiler.py
View file @
1bcfaa59
...
@@ -18,6 +18,8 @@ $Id$
...
@@ -18,6 +18,8 @@ $Id$
import
os
,
sys
import
os
,
sys
import
interfaces
import
interfaces
from
zope.interface
import
implements
# Some distros ship without profile
# Some distros ship without profile
try
:
try
:
from
profile
import
Profile
from
profile
import
Profile
...
@@ -69,7 +71,7 @@ class Profiled:
...
@@ -69,7 +71,7 @@ class Profiled:
Profiler statistics will be printed after the test results.
Profiler statistics will be printed after the test results.
'''
'''
__implements__
=
(
interfaces
.
IProfiled
,
)
implements
(
interfaces
.
IProfiled
)
def
runcall
(
self
,
*
args
,
**
kw
):
def
runcall
(
self
,
*
args
,
**
kw
):
return
apply
(
runcall
,
args
,
kw
)
return
apply
(
runcall
,
args
,
kw
)
...
...
lib/python/Testing/ZopeTestCase/testInterfaces.py
View file @
1bcfaa59
...
@@ -22,8 +22,8 @@ if __name__ == '__main__':
...
@@ -22,8 +22,8 @@ if __name__ == '__main__':
from
Testing.ZopeTestCase
import
*
from
Testing.ZopeTestCase
import
*
from
Testing.ZopeTestCase.interfaces
import
*
from
Testing.ZopeTestCase.interfaces
import
*
from
Interface.V
erify
import
verifyClass
from
zope.interface.v
erify
import
verifyClass
from
Interface.V
erify
import
verifyObject
from
zope.interface.v
erify
import
verifyObject
class
TestAbstractClasses
(
TestCase
):
class
TestAbstractClasses
(
TestCase
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment