set correct Type ('Discussion Item') for Comments.
svn path=/plone.app.discussion/trunk/; revision=27629
This commit is contained in:
		
							parent
							
								
									bded41ffa4
								
							
						
					
					
						commit
						6d414055bc
					
				@ -24,7 +24,7 @@ class Comment(DynamicType, Traversable, RoleManager, Owned, Implicit):
 | 
			
		||||
 | 
			
		||||
    implements(IComment)
 | 
			
		||||
 | 
			
		||||
    meta_type = portal_type = 'Discussion Item'
 | 
			
		||||
    meta_type = portal_type = Type = 'Discussion Item'
 | 
			
		||||
 | 
			
		||||
    __parent__ = None
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -40,6 +40,10 @@ class CommentTest(PloneTestCase):
 | 
			
		||||
        comment1.creator = "Jim"
 | 
			
		||||
        self.assertEquals("Jim", comment1.Creator())
 | 
			
		||||
 | 
			
		||||
    def test_type(self):
 | 
			
		||||
        comment1 = createObject('plone.Comment')
 | 
			
		||||
        self.assertEquals(comment1.Type, 'Discussion Item')
 | 
			
		||||
 | 
			
		||||
    def test_traversal(self):
 | 
			
		||||
        # make sure comments are traversable, have an id, absolute_url and physical path
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user