diff -r 9f314411cd04 -r c0ae3148b893 web/test/unittest_views_editforms.py --- a/web/test/unittest_views_editforms.py Fri Nov 27 19:04:26 2009 +0100 +++ b/web/test/unittest_views_editforms.py Fri Nov 27 22:04:54 2009 +0100 @@ -5,7 +5,7 @@ :contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr :license: GNU Lesser General Public License, v2.1 - http://www.gnu.org/licenses """ -from logilab.common.testlib import unittest_main +from logilab.common.testlib import unittest_main, mock_object from logilab.common.compat import any from cubicweb.devtools.apptest import EnvBasedTC from cubicweb.devtools.testlib import WebTest @@ -154,13 +154,16 @@ geid = self.execute('CWGroup X LIMIT 1')[0][0] rset = self.execute('CWUser X LIMIT 1') self.view('inline-edition', rset, row=0, col=0, rtype='in_group', - peid=geid, role='object', template=None, i18nctx='').source + peid=geid, role='object', template=None, i18nctx='', + pform=MOCKPFORM).source def test_automatic_inline_creation_formview(self): geid = self.execute('CWGroup X LIMIT 1')[0][0] self.view('inline-creation', None, etype='CWUser', rtype='in_group', - peid=geid, template=None, i18nctx='', role='object').source + peid=geid, template=None, i18nctx='', role='object', + pform=MOCKPFORM).source +MOCKPFORM = mock_object(form_previous_values={}, form_valerror=None) if __name__ == '__main__': unittest_main()