[Zope-CVS] CVS: Products/Zelenium - CHANGES.txt:1.11 zuite.py:1.6
Tres Seaver
tseaver at zope.com
Wed Apr 27 21:09:40 EDT 2005
Update of /cvs-repository/Products/Zelenium
In directory cvs.zope.org:/tmp/cvs-serv19551
Modified Files:
CHANGES.txt zuite.py
Log Message:
- Force order support UI to show in teeth of EE's monkey patching.
=== Products/Zelenium/CHANGES.txt 1.10 => 1.11 ===
--- Products/Zelenium/CHANGES.txt:1.10 Tue Apr 26 22:41:07 2005
+++ Products/Zelenium/CHANGES.txt Wed Apr 27 21:09:09 2005
@@ -1,5 +1,16 @@
Zelenium Product Changelog
+ After Zelenium-0.3.1
+
+ - Force Zuite objects to show order support, even in the presence of
+ ExternalEditor, whose monkey patching seems to trip it up. Surface
+ the EE icon, if the product is available
+
+ Note: we are *forking* OFS/dtml/main.dtml and the version in
+ ExteranalEditor/manage_main.dtml to surface order support, which
+ is a pretty brutal hack. We should probably get ExteranalEditor
+ fixed, instead, and rip out the forked copy.
+
Zelenium-0.3.1 (2005/04/26)
- CVS tag: 'Zelenium-0_3_1'
=== Products/Zelenium/zuite.py 1.5 => 1.6 ===
--- Products/Zelenium/zuite.py:1.5 Tue Apr 26 22:41:07 2005
+++ Products/Zelenium/zuite.py Wed Apr 27 21:09:09 2005
@@ -1,5 +1,7 @@
""" Classes: Zuite
+Zuite instances are collections of Zelenium test cases.
+
$Id$
"""
import os
@@ -8,6 +10,7 @@
import StringIO
from AccessControl.SecurityInfo import ClassSecurityInfo
+from App.special_dtml import DTMLFile
from DateTime.DateTime import DateTime
from Globals import package_home
from Globals import InitializeClass
@@ -183,15 +186,19 @@
)
security = ClassSecurityInfo()
- security.declareObjectProtected(View)
+ security.declareObjectProtected( View )
+
+ security.declareProtected( ManageSeleniumTestCases, 'manage_main' )
+ manage_main = DTMLFile( 'suiteMain', _WWW_DIR )
- security.declareProtected(View, 'index_html')
+ security.declareProtected( View, 'index_html' )
index_html = PageTemplateFile( 'suiteView', _WWW_DIR )
- security.declareProtected(View, 'test_suite_html')
+ security.declareProtected( View, 'test_suite_html' )
test_suite_html = PageTemplateFile( 'suiteTests', _WWW_DIR )
- security.declareProtected(View, 'listTestCases')
+
+ security.declareProtected( View, 'listTestCases' )
def listTestCases( self ):
""" Return a list of our contents which qualify as test cases.
"""
@@ -199,6 +206,7 @@
for x in self.objectItems( [ 'File', 'Page Template' ] )
if x[ 0 ].startswith('test') ]
+
def __getitem__( self, key, default=_MARKER ):
if key in self.objectIds():
@@ -212,6 +220,7 @@
raise KeyError, key
+
security.declarePublic('postResults')
def postResults(self, REQUEST):
""" Record the results of a test run.
@@ -336,8 +345,8 @@
, 'Test case: %s' % test_id
, unquote( rfg( test_id ) )
, 'text/html'
- )
- )
+ ) )
+
security.declarePrivate('_listProductInfo')
def _listProductInfo( self ):
@@ -368,6 +377,7 @@
now_str = now.strftime( '%Y-%m-%d' )
return '%s-%s.zip' % ( self.getId(), now_str )
+
security.declareProtected(ManageSeleniumTestCases, 'manage_getZipFile')
def manage_getZipFile(self, archive_name=None, RESPONSE=None):
""" Export the test suite as a zip file.
@@ -386,6 +396,7 @@
'inline;filename=%s' % archive_name )
RESPONSE.write(bits)
+
security.declareProtected(ManageSeleniumTestCases, 'manage_createSnapshot')
def manage_createSnapshot(self, archive_name=None, RESPONSE=None):
""" Save the test suite as a zip file *in the zuite*.
@@ -402,6 +413,7 @@
, 'Snapshot+added'
) )
+
security.declarePrivate('_getFilename')
def _getFilename(self, name):
""" Convert 'name' to a suitable filename, if needed.
@@ -411,6 +423,7 @@
return name
+
security.declarePrivate('_getZipFile')
def _getZipFile(self):
""" Generate a zip file containing both tests and scaffolding.
@@ -440,6 +453,7 @@
archive.close()
return stream.getvalue()
+
InitializeClass(Zuite)
More information about the Zope-CVS
mailing list