Fixed several failing Publishing tests.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@28961 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
N Smith
2011-07-12 16:08:06 +00:00
parent 90102ca33e
commit a750e322f7
5 changed files with 32 additions and 19 deletions

View File

@@ -43,6 +43,7 @@ import org.alfresco.util.BaseSpringTest;
import org.alfresco.util.GUID;
import org.junit.After;
import org.junit.Before;
import org.mockito.Mockito;
/**
* @author Nick Smith
@@ -118,9 +119,14 @@ public abstract class AbstractPublishingIntegrationTest extends BaseSpringTest
protected ChannelType mockChannelType()
{
ChannelType channelType = mock(ChannelType.class);
when(channelType.getId()).thenReturn(channelTypeId);
when(channelType.getChannelNodeType()).thenReturn(TYPE_DELIVERY_CHANNEL);
mockChannelTypeBehaviour(channelType);
return channelType;
}
protected void mockChannelTypeBehaviour(ChannelType channelType)
{
when(channelType.getId()).thenReturn(channelTypeId);
when(channelType.getChannelNodeType()).thenReturn(TYPE_DELIVERY_CHANNEL);
}
}