Changeset 335

Show
Ignore:
Timestamp:
04/30/08 20:01:42 (8 months ago)
Author:
johnbywater
Message:

Adding 'markdown text' model attribute type.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/dm/dom/meta.py

    r326 r335  
    328328 
    329329 
     330class MarkdownText(Text): 
     331    "Models a 'markdown' textual attribute." 
     332 
     333    # Todo: Figure out how to render separately from read value? 
     334 
     335    pass 
     336 
     337 
    330338class Url(String): 
    331339    "Models a domain object url attribute." 
  • trunk/src/dm/dom/metatest.py

    r310 r335  
    1212        unittest.makeSuite(TestString), 
    1313        unittest.makeSuite(TestText), 
     14        unittest.makeSuite(TestMarkdownText), 
    1415        unittest.makeSuite(TestUrl), 
    1516        unittest.makeSuite(TestPassword), 
     
    103104     
    104105 
     106class TestMarkdownText(MetaAttrTestCase): 
     107 
     108    fieldClass = dm.dom.meta.MarkdownText 
     109    typeName = 'MarkdownText' 
     110    isValueObject = True 
     111    htmlValue = 'My Text' 
     112    htmlRepr = 'My Text' 
     113    domValue = 'My Text' 
     114    dbValue = 'My Text' 
     115     
     116 
    105117class TestUrl(MetaAttrTestCase): 
    106118