Author: justi9
Date: 2008-04-09 11:32:49 -0400 (Wed, 09 Apr 2008)
New Revision: 1888
Modified:
mgmt/cumin/python/cumin/test.py
mgmt/cumin/python/cumin/widgets.py
Log:
Add submit and cancel methods to CuminForm, for use by tests.
Modified: mgmt/cumin/python/cumin/test.py
===================================================================
--- mgmt/cumin/python/cumin/test.py 2008-04-09 15:32:09 UTC (rev 1887)
+++ mgmt/cumin/python/cumin/test.py 2008-04-09 15:32:49 UTC (rev 1888)
@@ -204,7 +204,7 @@
(self.env.broker_client.host, self.env.broker_client.port)
form.addrs.get(s).append(addr)
form.groups.get(s).append(None)
- form.submit.set(s, True)
+ form.submit(s)
p.process(s)
@@ -249,7 +249,7 @@
form = p.show_main(s).show_broker_group(s, None).show_add(s)
form.group_name.set(s, session.id)
- form.submit.set(s, True)
+ form.submit(s)
p.process(s)
@@ -278,7 +278,7 @@
form = p.show_main(s).show_broker_group(s, group).show_edit(s)
form.group_name.set(s, session.id + "%;&#\\")
- form.submit.set(s, True)
+ form.submit(s)
p.process(s)
@@ -296,7 +296,7 @@
group = self.env.broker_group
form = p.show_main(s).show_broker_group(s, group).show_remove(s)
- form.submit.set(s, True)
+ form.submit(s)
p.process(s)
Modified: mgmt/cumin/python/cumin/widgets.py
===================================================================
--- mgmt/cumin/python/cumin/widgets.py 2008-04-09 15:32:09 UTC (rev 1887)
+++ mgmt/cumin/python/cumin/widgets.py 2008-04-09 15:32:49 UTC (rev 1888)
@@ -121,6 +121,12 @@
self.__submit.set_tab_index(200)
self.add_child(self.__submit)
+ def submit(self, session):
+ self.__submit.set(session, True)
+
+ def cancel(self, session):
+ self.__cancel.set(session, True)
+
def do_process(self, session, *args):
self.page.set_modal(session, True)
Show replies by date