some test for meta attributes (XXX should be in yams) tls-sprint
authorsylvain.thenault@logilab.fr
Thu, 12 Mar 2009 19:43:44 +0100
branchtls-sprint
changeset 1102 054dfee29bfc
parent 1101 0c067de38e46
child 1103 f719caf263de
some test for meta attributes (XXX should be in yams)
entities/test/unittest_base.py
--- a/entities/test/unittest_base.py	Thu Mar 12 19:39:34 2009 +0100
+++ b/entities/test/unittest_base.py	Thu Mar 12 19:43:44 2009 +0100
@@ -53,6 +53,12 @@
         self.assertEquals(card.default_content_format(), 'text/rest')
         
 
+    def test_entity_meta_attributes(self):
+        # XXX move to yams
+        self.assertEquals(self.schema['EUser'].meta_attributes(), {})
+        self.assertEquals(dict((str(k), v) for k, v in self.schema['Card'].meta_attributes().iteritems()),
+                          {'content_format': ('format', 'content')})
+        
 
 class EUserTC(BaseEntityTC):
     def test_dc_title_and_name(self):