org.alfresco.repo.web.scripts.activities
Class SiteActivitySystemTest
java.lang.Object
junit.framework.Assert
junit.framework.TestCase
org.alfresco.repo.web.scripts.activities.SiteActivitySystemTest
- All Implemented Interfaces:
- junit.framework.Test
public class SiteActivitySystemTest
- extends junit.framework.TestCase
Simple Activity Service system test (requires remote repo to be running) using site (membership) activities
Method Summary |
protected void |
addAndUpdateMemberships(java.lang.String siteId,
java.lang.String ticket,
boolean includeUser4)
|
protected java.lang.String |
callDeleteWebScript(java.lang.String urlString,
java.lang.String ticket)
|
protected java.lang.String |
callGetWebScript(java.lang.String urlString,
java.lang.String ticket)
|
protected java.lang.String |
callLoginWebScript(java.lang.String serviceUrl,
java.lang.String username,
java.lang.String password)
|
protected java.lang.String |
callPostWebScript(java.lang.String urlString,
java.lang.String ticket,
java.lang.String data)
|
protected java.lang.String |
callPutWebScript(java.lang.String urlString,
java.lang.String ticket,
java.lang.String data)
|
protected void |
createSite(java.lang.String siteId,
boolean isPublic,
java.lang.String ticket)
|
protected void |
createUser(java.lang.String ticket,
java.lang.String username,
java.lang.String password)
|
protected void |
getSite(java.lang.String siteId,
java.lang.String ticket)
|
protected void |
getSiteFeed(java.lang.String siteId,
java.lang.String ticket,
int expectedCount)
|
protected void |
getUserFeed(java.lang.String userId,
java.lang.String ticket,
boolean isAdmin,
int expectedCount)
|
protected void |
getUserFeed(java.lang.String userId,
java.lang.String siteId,
java.lang.String ticket,
boolean isAdmin,
boolean excludeThisUser,
boolean excludeOtherUsers,
int expectedCount)
|
protected void |
removeMemberships(java.lang.String siteId,
java.lang.String ticket,
boolean includeUser4)
|
protected void |
setUp()
|
protected void |
tearDown()
|
void |
testAddAndUpdateMembershipsWithPause()
|
void |
testCreateSites()
|
void |
testGetSiteFeedsAfterAddAndUpdateMemberships()
|
void |
testGetSiteFeedsAfterRemoveMemberships()
|
void |
testGetSiteFeedsBefore()
|
void |
testGetSites()
|
void |
testGetUserFeedsAfter()
|
void |
testGetUserFeedsBefore()
|
void |
testLogin()
|
void |
testRemoveMembershipsWithPause()
|
void |
testUserFeedControls()
|
Methods inherited from class junit.framework.TestCase |
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString |
Methods inherited from class junit.framework.Assert |
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SiteActivitySystemTest
public SiteActivitySystemTest()
setUp
protected void setUp()
throws java.lang.Exception
- Overrides:
setUp
in class junit.framework.TestCase
- Throws:
java.lang.Exception
tearDown
protected void tearDown()
throws java.lang.Exception
- Overrides:
tearDown
in class junit.framework.TestCase
- Throws:
java.lang.Exception
testLogin
public void testLogin()
throws java.lang.Exception
- Throws:
java.lang.Exception
testCreateSites
public void testCreateSites()
throws java.lang.Exception
- Throws:
java.lang.Exception
createSite
protected void createSite(java.lang.String siteId,
boolean isPublic,
java.lang.String ticket)
throws java.lang.Exception
- Throws:
java.lang.Exception
testGetSites
public void testGetSites()
throws java.lang.Exception
- Throws:
java.lang.Exception
getSite
protected void getSite(java.lang.String siteId,
java.lang.String ticket)
throws java.lang.Exception
- Throws:
java.lang.Exception
testGetSiteFeedsBefore
public void testGetSiteFeedsBefore()
throws java.lang.Exception
- Throws:
java.lang.Exception
getSiteFeed
protected void getSiteFeed(java.lang.String siteId,
java.lang.String ticket,
int expectedCount)
throws java.lang.Exception
- Throws:
java.lang.Exception
testGetUserFeedsBefore
public void testGetUserFeedsBefore()
throws java.lang.Exception
- Throws:
java.lang.Exception
getUserFeed
protected void getUserFeed(java.lang.String userId,
java.lang.String ticket,
boolean isAdmin,
int expectedCount)
throws java.lang.Exception
- Throws:
java.lang.Exception
getUserFeed
protected void getUserFeed(java.lang.String userId,
java.lang.String siteId,
java.lang.String ticket,
boolean isAdmin,
boolean excludeThisUser,
boolean excludeOtherUsers,
int expectedCount)
throws java.lang.Exception
- Throws:
java.lang.Exception
testUserFeedControls
public void testUserFeedControls()
throws java.lang.Exception
- Throws:
java.lang.Exception
testAddAndUpdateMembershipsWithPause
public void testAddAndUpdateMembershipsWithPause()
throws java.lang.Exception
- Throws:
java.lang.Exception
testGetSiteFeedsAfterAddAndUpdateMemberships
public void testGetSiteFeedsAfterAddAndUpdateMemberships()
throws java.lang.Exception
- Throws:
java.lang.Exception
testRemoveMembershipsWithPause
public void testRemoveMembershipsWithPause()
throws java.lang.Exception
- Throws:
java.lang.Exception
addAndUpdateMemberships
protected void addAndUpdateMemberships(java.lang.String siteId,
java.lang.String ticket,
boolean includeUser4)
throws java.lang.Exception
- Throws:
java.lang.Exception
removeMemberships
protected void removeMemberships(java.lang.String siteId,
java.lang.String ticket,
boolean includeUser4)
throws java.lang.Exception
- Throws:
java.lang.Exception
testGetSiteFeedsAfterRemoveMemberships
public void testGetSiteFeedsAfterRemoveMemberships()
throws java.lang.Exception
- Throws:
java.lang.Exception
testGetUserFeedsAfter
public void testGetUserFeedsAfter()
throws java.lang.Exception
- Throws:
java.lang.Exception
callGetWebScript
protected java.lang.String callGetWebScript(java.lang.String urlString,
java.lang.String ticket)
throws java.net.MalformedURLException,
java.net.URISyntaxException,
java.io.IOException
- Throws:
java.net.MalformedURLException
java.net.URISyntaxException
java.io.IOException
callDeleteWebScript
protected java.lang.String callDeleteWebScript(java.lang.String urlString,
java.lang.String ticket)
throws java.net.MalformedURLException,
java.net.URISyntaxException,
java.io.IOException
- Throws:
java.net.MalformedURLException
java.net.URISyntaxException
java.io.IOException
callPostWebScript
protected java.lang.String callPostWebScript(java.lang.String urlString,
java.lang.String ticket,
java.lang.String data)
throws java.net.MalformedURLException,
java.net.URISyntaxException,
java.io.IOException
- Throws:
java.net.MalformedURLException
java.net.URISyntaxException
java.io.IOException
callPutWebScript
protected java.lang.String callPutWebScript(java.lang.String urlString,
java.lang.String ticket,
java.lang.String data)
throws java.net.MalformedURLException,
java.net.URISyntaxException,
java.io.IOException
- Throws:
java.net.MalformedURLException
java.net.URISyntaxException
java.io.IOException
callLoginWebScript
protected java.lang.String callLoginWebScript(java.lang.String serviceUrl,
java.lang.String username,
java.lang.String password)
throws java.net.MalformedURLException,
java.net.URISyntaxException,
java.io.IOException
- Throws:
java.net.MalformedURLException
java.net.URISyntaxException
java.io.IOException
createUser
protected void createUser(java.lang.String ticket,
java.lang.String username,
java.lang.String password)
throws org.json.JSONException,
java.io.IOException,
java.net.URISyntaxException
- Throws:
org.json.JSONException
java.io.IOException
java.net.URISyntaxException
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.