org.alfresco.repo.web.scripts.forms
Class FormRestApiJsonPost_Test

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.alfresco.repo.web.scripts.BaseWebScriptTest
              extended by org.alfresco.repo.web.scripts.forms.AbstractTestFormRestApi
                  extended by org.alfresco.repo.web.scripts.forms.FormRestApiJsonPost_Test
All Implemented Interfaces:
junit.framework.Test

public class FormRestApiJsonPost_Test
extends AbstractTestFormRestApi


Nested Class Summary
 
Nested classes/interfaces inherited from class org.alfresco.repo.web.scripts.BaseWebScriptTest
BaseWebScriptTest.BaseWebScriptTestListener, BaseWebScriptTest.HttpMethodResponse, BaseWebScriptTest.PatchMethod, BaseWebScriptTest.RemoteServer, BaseWebScriptTest.WebScriptTestListener
 
Field Summary
 
Fields inherited from class org.alfresco.repo.web.scripts.forms.AbstractTestFormRestApi
APPLICATION_JSON, associatedDoc_A, associatedDoc_B, associatedDoc_C, associatedDoc_D, associatedDoc_E, childDoc_A, childDoc_B, childDoc_C, childDoc_D, childDoc_E, containerNodeRef, containingNodeUpdateUrl, containingNodeUrl, FORM_DEF_URL, nodeService, referencingDocNodeRef, referencingNodeUpdateUrl, refNodePropertiesAfterCreation, TEST_FORM_DESCRIPTION, TEST_FORM_TITLE, testFolderNodeRef, transactionService
 
Constructor Summary
FormRestApiJsonPost_Test()
           
 
Method Summary
 void testAddAssocThatAlreadyExists()
          This test method attempts to add the same association twice.
 void testAddChildAssocThatAlreadyExists()
          This test method attempts to add the same child association twice.
 void testAddNewAssociationsToNode()
          This test method attempts to add new associations between existing nodes.
 void testAddNewChildAssociationsToNode()
          This test method attempts to add new associations between existing nodes.
 void testRemoveAssociationsFromNode()
          This test method attempts to remove an existing association between two existing nodes.
 void testRemoveAssocThatDoesNotExist()
          This test method attempts to remove an association that does not exist.
 void testRemoveChildAssociationsFromNode()
          This test method attempts to remove an existing child association between two existing nodes.
 void testRemoveChildAssocThatDoesNotExist()
          This test method attempts to remove a child association that does not exist.
 void testSimpleJsonPostRequest()
           
 
Methods inherited from class org.alfresco.repo.web.scripts.forms.AbstractTestFormRestApi
createTestNode, sendGetReq, setUp, tearDown
 
Methods inherited from class org.alfresco.repo.web.scripts.BaseWebScriptTest
getDefaultRunAs, getRemoteServer, getServer, isLogEnabled, log, sendLocalRequest, sendRemoteRequest, sendRequest, sendRequest, setCustomContext, setDefaultRunAs, setListener, setRemoteServer, setTraceReqRes
 
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
 

Constructor Detail

FormRestApiJsonPost_Test

public FormRestApiJsonPost_Test()
Method Detail

testSimpleJsonPostRequest

public void testSimpleJsonPostRequest()
                               throws java.io.IOException,
                                      org.json.JSONException
Throws:
java.io.IOException
org.json.JSONException

testAddNewAssociationsToNode

public void testAddNewAssociationsToNode()
                                  throws java.lang.Exception
This test method attempts to add new associations between existing nodes.

Throws:
java.lang.Exception

testRemoveAssociationsFromNode

public void testRemoveAssociationsFromNode()
                                    throws java.lang.Exception
This test method attempts to remove an existing association between two existing nodes.

Throws:
java.lang.Exception

testAddAssocThatAlreadyExists

public void testAddAssocThatAlreadyExists()
                                   throws java.lang.Exception
This test method attempts to add the same association twice. This attempt will not succeed, but the test case is to confirm that there is no exception thrown back across the REST API.

Throws:
java.lang.Exception

testRemoveAssocThatDoesNotExist

public void testRemoveAssocThatDoesNotExist()
                                     throws java.lang.Exception
This test method attempts to remove an association that does not exist. This attempt will not succeed, but the test case is to confirm that there is no exception thrown back across the REST API.

Throws:
java.lang.Exception

testAddNewChildAssociationsToNode

public void testAddNewChildAssociationsToNode()
                                       throws java.lang.Exception
This test method attempts to add new associations between existing nodes.

Throws:
java.lang.Exception

testRemoveChildAssociationsFromNode

public void testRemoveChildAssociationsFromNode()
                                         throws java.lang.Exception
This test method attempts to remove an existing child association between two existing nodes.

Throws:
java.lang.Exception

testAddChildAssocThatAlreadyExists

public void testAddChildAssocThatAlreadyExists()
                                        throws java.lang.Exception
This test method attempts to add the same child association twice. This attempt will not succeed, but the test case is to confirm that there is no exception thrown back across the REST API.

Throws:
java.lang.Exception

testRemoveChildAssocThatDoesNotExist

public void testRemoveChildAssocThatDoesNotExist()
                                          throws java.lang.Exception
This test method attempts to remove a child association that does not exist. This attempt will not succeed, but the test case is to confirm that there is no exception thrown back across the REST API.

Throws:
java.lang.Exception


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.