|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.silverpeas.comment.service.notification.CommentUserNotificationServiceTest
@ContextConfiguration(locations="/spring-comment-user-notification.xml") public class CommentUserNotificationServiceTest
Unit tests notification of the users at comment adding on a given Silverpeas content.
| Constructor Summary | |
|---|---|
CommentUserNotificationServiceTest()
|
|
| Method Summary | |
|---|---|
protected static Classified |
aClassified()
|
protected void |
addAUserWithoutEnoughAccessRights()
|
void |
commentAddedShouldNotifyClassifiedAndCommentAuthors()
The commentAdded() method should notify both the author of the commented ad and the authors of all of the ad's comments. |
protected NotificationMetaData |
getCapturedInfoInNotification()
Gets the captured information from the notification sender at notifiyUser() call by the callback. |
protected CommentService |
mockCommentService()
Mocks the DefaultCommentService to use by the callback. |
protected void |
mockGetUserDetailReturnedValue()
|
protected NotificationSender |
mockNotificationSender()
Mocks the NotificationSender instance to use by the callback. |
void |
notificationsAreNotSentToUsersWithoutEnoughAccessRights()
Tests the notification about a comment isn't sent to the users that don't have enough rights to access the commented resource. |
void |
setUp()
|
static void |
setUpClass()
|
protected void |
setUpClassifiedComments()
Sets up all of the comments about the classified used in the current test. |
protected void |
setUpClassifieds()
|
void |
tearDown()
|
static void |
tearDownClass()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CommentUserNotificationServiceTest()
| Method Detail |
|---|
public static void setUpClass()
throws Exception
Exception
public static void tearDownClass()
throws Exception
Exception
public void setUp()
throws Exception
Exceptionpublic void tearDown()
public void commentAddedShouldNotifyClassifiedAndCommentAuthors()
throws Exception
Exception - if an error occurs during the test.
public void notificationsAreNotSentToUsersWithoutEnoughAccessRights()
throws Exception
Exception - if an error occurs during the test.protected void setUpClassifiedComments()
protected void addAUserWithoutEnoughAccessRights()
protected void setUpClassifieds()
protected static Classified aClassified()
protected CommentService mockCommentService()
throws Exception
Exception - - it is just for satisfying the contract of some called methods of
DefaultCommentService.
protected NotificationSender mockNotificationSender()
throws Exception
Exception - - it is just for satisfying the contract of some called methods of
NotifySender.protected void mockGetUserDetailReturnedValue()
protected NotificationMetaData getCapturedInfoInNotification()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||