org.kuali.rice.ken.test.util
Class MockObjectsUtil

java.lang.Object
  extended by org.kuali.rice.ken.test.util.MockObjectsUtil

public final class MockObjectsUtil
extends Object

This class helps to provide common mock objects for testing and also helper methods to build instances of objects.

Author:
Kuali Rice Team (rice.collab@kuali.org)

Method Summary
static NotificationBo buildTestNotification(String deliveryType, Timestamp sendDateTime, Timestamp autoRemoveDateTime, NotificationContentTypeBo contentType, String content, NotificationPriorityBo priority, NotificationProducerBo producer, NotificationChannelBo channel, List<NotificationRecipientBo> recipients, List<NotificationSenderBo> senders)
          This method is a helper to build a Notification instance.
static NotificationChannelBo buildTestNotificationChannel(String name, String description, boolean subscribable)
          This method is a helper to build a NotificationChannel instance.
static NotificationChannelReviewerBo buildTestNotificationChannelReviewer(MemberType reviewerType, String reviewerId)
          This method is a helper to build a NotificationChannelReviewer instance.
static NotificationContentTypeBo buildTestNotificationContentType(String name, String description, String namespace, String xsd, String xsl)
          This method is a helper to build a NotificationContentType instance.
static NotificationPriorityBo buildTestNotificationPriority(String name, String description, Integer order)
          This method is a helper to build a NotificationPriority instance.
static NotificationProducerBo buildTestNotificationProducer(String name, String description, String contactInfo)
          This method is a helper to build a NotificationProducer instance.
static NotificationRecipientBo buildTestNotificationRecipient(String recipientId, MemberType recipientType)
          This method is a helper to build a NotificationRecipient instance.
static NotificationSenderBo buildTestNotificationSender(String userId)
          This method is a helper to build a NotificationSender instance.
static NotificationChannelBo getTestChannel1()
          This method returns back a specific test mock object.
static NotificationChannelBo getTestChannel2()
          This method returns back a specific test mock object.
static NotificationContentTypeBo getTestContentType1()
          This method returns back a specific test mock object.
static NotificationPriorityBo getTestPriority1()
          This method returns back a specific test mock object.
static NotificationProducerBo getTestProducer1()
          This method returns back a specific test mock object.
static NotificationRecipientBo getTestRecipient1()
          This method returns back a specific test mock object.
static NotificationRecipientBo getTestRecipient2()
          This method returns back a specific test mock object.
static NotificationSenderBo getTestSender1()
          This method returns back a specific test mock object.
static NotificationSenderBo getTestSender2()
          This method returns back a specific test mock object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

buildTestNotificationChannel

public static final NotificationChannelBo buildTestNotificationChannel(String name,
                                                                       String description,
                                                                       boolean subscribable)
This method is a helper to build a NotificationChannel instance.

Parameters:
name -
description -
subscribable -
Returns:
NotificationChannel

getTestChannel1

public static final NotificationChannelBo getTestChannel1()
This method returns back a specific test mock object.

Returns:
NotificationChannel

getTestChannel2

public static final NotificationChannelBo getTestChannel2()
This method returns back a specific test mock object.

Returns:
NotificationChannel

buildTestNotificationProducer

public static final NotificationProducerBo buildTestNotificationProducer(String name,
                                                                         String description,
                                                                         String contactInfo)
This method is a helper to build a NotificationProducer instance.

Parameters:
name -
description -
contactInfo -
Returns:

buildTestNotificationChannelReviewer

public static final NotificationChannelReviewerBo buildTestNotificationChannelReviewer(MemberType reviewerType,
                                                                                       String reviewerId)
This method is a helper to build a NotificationChannelReviewer instance.

Parameters:
reviewerType -
reviewerId -
Returns:

getTestProducer1

public static final NotificationProducerBo getTestProducer1()
This method returns back a specific test mock object.

Returns:
NotificationProducer

buildTestNotificationContentType

public static final NotificationContentTypeBo buildTestNotificationContentType(String name,
                                                                               String description,
                                                                               String namespace,
                                                                               String xsd,
                                                                               String xsl)
This method is a helper to build a NotificationContentType instance.

Parameters:
name -
description -
namespace -
xsd -
Returns:
NotificationContentType

getTestContentType1

public static final NotificationContentTypeBo getTestContentType1()
This method returns back a specific test mock object.

Returns:
NotificationContentType

buildTestNotificationPriority

public static final NotificationPriorityBo buildTestNotificationPriority(String name,
                                                                         String description,
                                                                         Integer order)
This method is a helper to build a NotificationPriority instance.

Parameters:
name -
description -
order -
Returns:
NotificationPriority

getTestPriority1

public static final NotificationPriorityBo getTestPriority1()
This method returns back a specific test mock object.

Returns:
NotificationPriority

buildTestNotificationRecipient

public static final NotificationRecipientBo buildTestNotificationRecipient(String recipientId,
                                                                           MemberType recipientType)
This method is a helper to build a NotificationRecipient instance.

Parameters:
recipientId -
recipientType -
Returns:
NotificationRecipient

getTestRecipient1

public static final NotificationRecipientBo getTestRecipient1()
This method returns back a specific test mock object.

Returns:
NotificationRecipient

getTestRecipient2

public static final NotificationRecipientBo getTestRecipient2()
This method returns back a specific test mock object.

Returns:
NotificationRecipient

buildTestNotification

public static final NotificationBo buildTestNotification(String deliveryType,
                                                         Timestamp sendDateTime,
                                                         Timestamp autoRemoveDateTime,
                                                         NotificationContentTypeBo contentType,
                                                         String content,
                                                         NotificationPriorityBo priority,
                                                         NotificationProducerBo producer,
                                                         NotificationChannelBo channel,
                                                         List<NotificationRecipientBo> recipients,
                                                         List<NotificationSenderBo> senders)
This method is a helper to build a Notification instance.

Parameters:
recipientId -
recipientType -
Returns:
Notification

buildTestNotificationSender

public static final NotificationSenderBo buildTestNotificationSender(String userId)
This method is a helper to build a NotificationSender instance.

Parameters:
userId -
Returns:
NotificationSender

getTestSender1

public static final NotificationSenderBo getTestSender1()
This method returns back a specific test mock object.

Returns:
NotificationSender

getTestSender2

public static final NotificationSenderBo getTestSender2()
This method returns back a specific test mock object.

Returns:
NotificationSender


Copyright © 2005–2014 The Kuali Foundation. All rights reserved.