tisto
0558a9b739
Pep8
2012-01-14 07:26:01 +01:00
Timo Stollenwerk
41f5afa8b9
Use plone.app.testing in test_conversation.
...
svn path=/plone.app.discussion/trunk/; revision=48901
2011-04-16 09:27:15 +00:00
Hanno Schlichting
9db8909ea7
Avoid using deprecated test assertions, see http://docs.python.org/dev/library/unittest.html#deprecated-aliases for the full list
...
svn path=/plone.app.discussion/trunk/; revision=48881
2011-04-15 16:23:38 +00:00
Ross Patterson
3708429a37
Move some policy out of the conversation storage adapter into a view,
...
specifically "enabled()". Prevents having to replace/migrate
persistent objects to change policy which really only concerns the
context and possibly the request, not the conversation storage. Fixes
#11372 .
svn path=/plone.app.discussion/trunk/; revision=48849
2011-04-15 04:29:46 +00:00
Ross Patterson
586cd1fdb7
Don't add the annotation unless a comment is actually being added.
...
Fixes #11370 .
svn path=/plone.app.discussion/trunk/; revision=48829
2011-04-14 16:17:29 +00:00
Timo Stollenwerk
bf96d0082f
Remove "Plone 3 only" code; Do not monkey patch the BAD_TYPES vocabulary or plone.app.vocabularies anymore.
...
svn path=/plone.app.discussion/trunk/; revision=47311
2011-02-08 09:28:51 +00:00
Maurits van Rees
a2a17085a3
Nuke trailing white space
...
svn path=/plone.app.discussion/trunk/; revision=46366
2010-12-15 23:52:56 +00:00
Timo Stollenwerk
a8bfd7fc6e
Disable discussion by default.
...
svn path=/plone.app.discussion/trunk/; revision=46337
2010-12-14 17:58:46 +00:00
Timo Stollenwerk
a39ac82858
There is no need to set the comment title in the tests, since comments do not have title fields anymore.
...
svn path=/plone.app.discussion/trunk/; revision=44738
2010-10-31 11:09:32 +00:00
Timo Stollenwerk
c8cd370fc9
Use len(tuple()) instead of tuple() to make tests pass again.
...
svn path=/plone.app.discussion/trunk/; revision=44706
2010-10-30 19:26:51 +00:00
Timo Stollenwerk
093eaa393a
Use tuple() to test for generators. Thanks to otacon!
...
svn path=/plone.app.discussion/trunk/; revision=42096
2010-10-30 18:58:20 +00:00
Patrick Gerken
a7b1eb7c10
Change all datetime creations from now to utcnow
...
svn path=/plone.app.discussion/trunk/; revision=39726
2010-09-07 12:03:07 +00:00
Timo Stollenwerk
435040e0b2
Make pylint happy.
...
svn path=/plone.app.discussion/trunk/; revision=39287
2010-08-28 17:06:53 +00:00
Vincent Fretin
352a517a0a
Fixed the case where a folder has allow_discussion=False and
...
conversation.enabled() on a document in this folder returned False
instead of True because of allow_discussion acquisition.
svn path=/plone.app.discussion/trunk/; revision=38835
2010-08-20 11:52:05 +00:00
Timo Stollenwerk
a54a15a90f
Remove unnecessary imports and variables from test code.
...
svn path=/plone.app.discussion/trunk/; revision=37768
2010-07-13 10:45:53 +00:00
Timo Stollenwerk
cac0bae7a5
revert r37751.
...
svn path=/plone.app.discussion/trunk/; revision=37752
2010-07-12 13:47:53 +00:00
Timo Stollenwerk
eabf3bc890
Always use zope.component getUtility instead of queryUtility.
...
svn path=/plone.app.discussion/trunk/; revision=37751
2010-07-12 13:34:02 +00:00
Timo Stollenwerk
52ebbe2e71
Fix #2494228 : Remove comments as well when a content object is deleted.
...
svn path=/plone.app.discussion/trunk/; revision=34965
2010-03-16 15:06:43 +00:00
Timo Stollenwerk
6e226be248
failing test for Pivotal Tracker issue #2494228 added (comment out test for now).
...
svn path=/plone.app.discussion/trunk/; revision=34915
2010-03-16 11:09:40 +00:00
Timo Stollenwerk
ebc4c408e3
fix tests for conversation.getThreads generator.
...
svn path=/plone.app.discussion/trunk/; revision=34911
2010-03-16 10:52:25 +00:00
Timo Stollenwerk
6ca20c7514
Make test coverage happy. 1 second seems to be not enough to create a comment when running the test coverage.
...
svn path=/plone.app.discussion/trunk/; revision=33309
2010-01-23 07:26:19 +00:00
Timo Stollenwerk
e5f1a70de6
Make unit tests pass with Plone 3.3 again. Migration tests still failing.
...
svn path=/plone.app.discussion/trunk/; revision=30633
2009-10-16 12:11:58 +00:00
Timo Stollenwerk
b106262e31
plone.registry 1.0a2 changed methods to mixedCase (for_interface to forInterface).
...
svn path=/plone.app.discussion/trunk/; revision=28024
2009-07-12 19:13:42 +00:00
Timo Stollenwerk
360a758905
fix that enabled method check for FTI information of the current content object and not only for the "Document" portal_type.
...
svn path=/plone.app.discussion/trunk/; revision=27889
2009-07-07 14:48:39 +00:00
Timo Stollenwerk
41010fb32a
fix for "TypeError: can't pickle OIBTreeItems objects".
...
svn path=/plone.app.discussion/trunk/; revision=27778
2009-07-02 17:50:20 +00:00
Timo Stollenwerk
768b2095de
fix tests for bugfix 834504 ("Replies have a wrong path index.")
...
svn path=/plone.app.discussion/trunk/; revision=27661
2009-06-24 20:11:27 +00:00
Timo Stollenwerk
23d4b25218
allow_discussion on folder level implemented.
...
svn path=/plone.app.discussion/trunk/; revision=27517
2009-06-19 15:51:50 +00:00
Timo Stollenwerk
59586025be
add test to make sure that conversation.enabled on a folder always returns False.
...
svn path=/plone.app.discussion/trunk/; revision=27503
2009-06-18 21:12:38 +00:00
Timo Stollenwerk
34ee743bf3
remove all the unnecessary acquisition wrapping of conversation (since the conversationAdapterFactory now returns an aq wrapped conversation).
...
svn path=/plone.app.discussion/trunk/; revision=27501
2009-06-18 20:57:47 +00:00
Timo Stollenwerk
282e592c8f
test to understand the allow_discussion attribute added. I know that this is not a real test. We can remove it again at some point.
...
svn path=/plone.app.discussion/trunk/; revision=27467
2009-06-16 11:51:25 +00:00
Timo Stollenwerk
8fb254f73d
add optional workflow actions to the get_replies method of the comments viewlet.
...
switch from Acquisition.explicit to Acquisition.implicit for the comment class.
adjust test_comment to work with Acquisition.implicit.
svn path=/plone.app.discussion/trunk/; revision=27406
2009-06-13 16:46:37 +00:00
Timo Stollenwerk
e465d73c95
enabled property code added to conversation.
...
svn path=/plone.app.discussion/trunk/; revision=27380
2009-06-11 10:14:44 +00:00
Timo Stollenwerk
fdaa399983
test for comments viewlet added.
...
svn path=/plone.app.discussion/trunk/; revision=27325
2009-06-06 08:23:33 +00:00
Timo Stollenwerk
1ad75fa84f
some test code for allow_discussion added.
...
svn path=/plone.app.discussion/trunk/; revision=27305
2009-06-04 18:17:33 +00:00
Timo Stollenwerk
e671d78806
test for globally_enabled discussion added.
...
svn path=/plone.app.discussion/trunk/; revision=27302
2009-06-04 15:38:12 +00:00
Timo Stollenwerk
95405ee48f
test for testing if 'Discussion Item' is not in BAD_TYPES added.
...
svn path=/plone.app.discussion/trunk/; revision=27246
2009-05-31 17:54:14 +00:00
Timo Stollenwerk
731f83b706
remove the test_dict_api from test_comments.py, since the test_dict_api from test_conversation.py tests both IReplies adapters.
...
svn path=/plone.app.discussion/trunk/; revision=27106
2009-05-25 10:38:58 +00:00
Timo Stollenwerk
a948f15971
test delete comment for IReplies added.
...
svn path=/plone.app.discussion/trunk/; revision=27094
2009-05-24 16:23:49 +00:00
Martin Aspeli
9263a61a31
Delete children when deleting a parent comment.
...
svn path=/plone.app.discussion/trunk/; revision=27092
2009-05-24 16:19:21 +00:00
Martin Aspeli
a1e11cb5ee
Turn getComments() and getThreads() into generators.
...
svn path=/plone.app.discussion/trunk/; revision=27090
2009-05-24 16:04:49 +00:00
Timo Stollenwerk
2754d897e4
add some more assertions to test dict api.
...
svn path=/plone.app.discussion/trunk/; revision=27089
2009-05-24 15:36:31 +00:00
Timo Stollenwerk
a3ac44763b
test dict api for RepliesTest fixed (conversation returns all comments, replies return only top level comments).
...
svn path=/plone.app.discussion/trunk/; revision=27088
2009-05-24 15:30:16 +00:00
Timo Stollenwerk
cc45041a97
test dict api for RepliesTest added. (conversation currently returns the wrong number of items!)
...
svn path=/plone.app.discussion/trunk/; revision=27087
2009-05-24 15:25:49 +00:00
Martin Aspeli
ca0e299cdc
Fix dodgy IReplies adapter
...
svn path=/plone.app.discussion/trunk/; revision=27085
2009-05-24 14:19:06 +00:00
Timo Stollenwerk
69ab219582
test to add a comment to the IReplies adapter on a conversation added. not complete yet!
...
svn path=/plone.app.discussion/trunk/; revision=27084
2009-05-24 12:34:15 +00:00
Timo Stollenwerk
3733c1fab3
test for conversation dict operations added.
...
svn path=/plone.app.discussion/trunk/; revision=27082
2009-05-24 10:53:13 +00:00
Timo Stollenwerk
4263b8b5ed
test for last comment date added.
...
svn path=/plone.app.discussion/trunk/; revision=27073
2009-05-23 18:04:39 +00:00
Timo Stollenwerk
1f3c9ea896
errors in commentators test fixed.
...
svn path=/plone.app.discussion/trunk/; revision=27072
2009-05-23 17:17:06 +00:00
Timo Stollenwerk
fba5d3f752
commentators test added.
...
svn path=/plone.app.discussion/trunk/; revision=27069
2009-05-23 16:28:10 +00:00
Martin Aspeli
e296058c37
Adjust tests since getThreads() is not implemented
...
svn path=/plone.app.discussion/trunk/; revision=27067
2009-05-23 16:12:13 +00:00