web/test/unittest_form.py
changeset 3185 bd0126d17e83
parent 3023 7864fee8b4ec
parent 3176 b94703b131ad
child 3524 a3431f4e2f40
equal deleted inserted replaced
3163:edfe43ceaa35 3185:bd0126d17e83
    51         self.execute('SET X tags Y WHERE X is Tag, Y is BlogEntry')
    51         self.execute('SET X tags Y WHERE X is Tag, Y is BlogEntry')
    52         unrelated = [reid for rview, reid in form1.subject_relation_vocabulary('tags')]
    52         unrelated = [reid for rview, reid in form1.subject_relation_vocabulary('tags')]
    53         self.failIf(b.eid in unrelated, unrelated)
    53         self.failIf(b.eid in unrelated, unrelated)
    54         unrelated = [reid for rview, reid in form2.object_relation_vocabulary('tags')]
    54         unrelated = [reid for rview, reid in form2.object_relation_vocabulary('tags')]
    55         self.failIf(t.eid in unrelated, unrelated)
    55         self.failIf(t.eid in unrelated, unrelated)
       
    56 
    56 
    57 
    57     def test_form_field_vocabulary_new_entity(self):
    58     def test_form_field_vocabulary_new_entity(self):
    58         e = self.vreg['etypes'].etype_class('CWUser')(self.request())
    59         e = self.vreg['etypes'].etype_class('CWUser')(self.request())
    59         form = EntityFieldsForm(e.req, None, entity=e)
    60         form = EntityFieldsForm(e.req, None, entity=e)
    60         unrelated = [rview for rview, reid in form.subject_relation_vocabulary('in_group')]
    61         unrelated = [rview for rview, reid in form.subject_relation_vocabulary('in_group')]