web/test/unittest_views_basecontrollers.py
branchstable
changeset 8504 f21c72928662
parent 8487 017af22e7678
child 8544 3d049071957e
equal deleted inserted replaced
8500:bfc1875ce9e3 8504:f21c72928662
   779         def js_foo(self):
   779         def js_foo(self):
   780             return 12
   780             return 12
   781         res, req = self.remote_call('foo')
   781         res, req = self.remote_call('foo')
   782         self.assertEqual(res, '12')
   782         self.assertEqual(res, '12')
   783 
   783 
       
   784     def test_monkeypatch_jsoncontroller_stdfunc(self):
       
   785         @monkeypatch(JSonController)
       
   786         @jsonize
       
   787         def js_reledit_form(self):
       
   788             return 12
       
   789         res, req = self.remote_call('reledit_form')
       
   790         self.assertEqual(res, '12')
       
   791 
   784 
   792 
   785 class UndoControllerTC(CubicWebTC):
   793 class UndoControllerTC(CubicWebTC):
   786 
   794 
   787     def setup_database(self):
   795     def setup_database(self):
   788         req = self.request()
   796         req = self.request()