示例#1
0
文件: tests.py 项目: boothead/karl
 def __init__(self, title, text, description, creator):
     DummyModel.__init__(self,
                         title=title,
                         text=text,
                         description=description,
                         creator=creator)
     self['attachments'] = DummyModel()
示例#2
0
 def __init__(self, *args, **kw):
     DummyModel.__init__(self)
     for item in kw.items():
         setattr(self, item[0], item[1])
     self._alert_prefs = {}
     self._pending_alerts = []
     if 'security_state' not in kw:
         self.security_state = 'active'
示例#3
0
 def __init__(self):
     DummyModel.__init__(self)
     self[u'profiles'] = DummyModel()
     dummies = [
         (u'dummy1', u'Dummy One'),
         (u'dummy2', u'Dummy Two'),
         (u'dummy3', u'Dummy Three'),
         ]
     for dummy in dummies:
         self[u'profiles'][0] = DummyModel(title=dummy[1])
     self[u'communities'] = DummyModel()
示例#4
0
 def __init__(self):
     DummyModel.__init__(self)
     root = DummyRoot()
     root["communities"]["community"] = self
示例#5
0
文件: testing.py 项目: cguardia/karl
 def __init__(self, *args, **kw):
     DummyModel.__init__(self)
     for item in kw.items():
         setattr(self, item[0], item[1])
     self._alert_prefs = {}
     self._pending_alerts = []