org.kuali.rice.kew.routeheader
Class AppDocStatusTest
java.lang.Object
   org.kuali.rice.test.BaseRiceTestCase
org.kuali.rice.test.BaseRiceTestCase
       org.kuali.rice.test.RiceTestCase
org.kuali.rice.test.RiceTestCase
           org.kuali.rice.test.RiceInternalSuiteDataTestCase
org.kuali.rice.test.RiceInternalSuiteDataTestCase
               org.kuali.rice.test.BaseModuleTestCase
org.kuali.rice.test.BaseModuleTestCase
                   org.kuali.rice.test.BaselineTestCase
org.kuali.rice.test.BaselineTestCase
                       org.kuali.rice.kew.test.KEWTestCase
org.kuali.rice.kew.test.KEWTestCase
                           org.kuali.rice.kew.routeheader.AppDocStatusTest
org.kuali.rice.kew.routeheader.AppDocStatusTest
- All Implemented Interfaces: 
- MethodAware
- public class AppDocStatusTest 
- extends KEWTestCase
 
 
 
 
 
 
 
 
 
| Method Summary | 
| protected  void | assertAppDocStatuses(String documentId,
                                         String[] appDocStatuses)Verifies the document application document status history
 | 
| protected  void | assertSearchStatus(String documentTypeName,
                                     Person user,
                                     String appDocStatus,
                                     int expected,
                                     long changed)Verifies the DocumentSearchService finds documents with a given app document status
 | 
| protected  void | loadTestData()
 | 
|  void | testAppDocStatusValuesNotDefined()This method is similar to the above test, except that the doctype definition
 does NOT specify a valid set of values.
 | 
|  void | testInvalidAppDocStatusValue()This test attempts to set an invalid status value for a document that has a valid set
 of statuses defined.
 | 
|  void | testSearching()
 | 
|  void | testValidAppDocStatus()This method performs several positive tests related to Application Document Status
 For these tests the doctype definition defines a valid set of statuses.
 | 
 
| Methods inherited from class org.kuali.rice.kew.test.KEWTestCase | 
| clearCacheManagers, getGroupIdForName, getLoadApplicationLifecycle, getPerTestLifecycles, getPerTestTablesNotToClear, getPerTestTablesToClear, getPrincipalIdForName, getPrincipalNameForId, getSuiteLifecycles, getTransactionTemplate, loadDefaultTestData, loadPerTestData, loadSuiteTestData, loadXmlFile, loadXmlFile, loadXmlFileFromFileSystem, loadXmlStream, setUpAfterDataLoad | 
 
 
 
 
| Methods inherited from class org.kuali.rice.test.RiceTestCase | 
| configureLogging, dumpMemory, getBaseDir, getConfigLocations, getFullTestName, getModuleTestConfigLocation, getRiceMasterDefaultConfigFile, getTestHarnessConfig, getTestHarnessSpringBeansLocation, getTestHarnessSpringResourceLoader, getUserDir, logAfterRun, logBeforeRun, report, setBaseDirSystemProperty, setClearTables, setModuleName, setUpInternal, startLifecycles, startSuiteDataLoaderLifecycles, stopLifecycles, tearDown | 
 
 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
 
AppDocStatusTest
public AppDocStatusTest()
loadTestData
protected void loadTestData()
                     throws Exception
- 
- Overrides:
- loadTestDatain class- KEWTestCase
 
- 
- Throws:
- Exception
 
testValidAppDocStatus
public void testValidAppDocStatus()
                           throws Exception
- This method performs several positive tests related to Application Document Status
 For these tests the doctype definition defines a valid set of statuses.
 It also defines two status transitions in the route path
 It tests:
        - That the AppDocStatus is properly set by the workflow engine during
    appropriate transitions.
  - That the AppDocStatus may be retrieved by the client API
  - That the AppDocStatus may be set by the client API
  - That a history of AppDocStatus transitions is created.
 
- 
- Throws:
- Exception
 
testAppDocStatusValuesNotDefined
public void testAppDocStatusValuesNotDefined()
                                      throws Exception
- This method is similar to the above test, except that the doctype definition
 does NOT specify a valid set of values.  This means that the value can be any valid string.
 
- 
- Throws:
- Exception
 
testInvalidAppDocStatusValue
public void testInvalidAppDocStatusValue()
                                  throws Exception
- This test attempts to set an invalid status value for a document that has a valid set
 of statuses defined.
 It expects to throw a WorkflowRuntimeException when attempting to set the invalid status value.
 
- 
- Throws:
- Exception
 
testSearching
public void testSearching()
                   throws InterruptedException
- 
- Throws:
- InterruptedException
 
assertSearchStatus
protected void assertSearchStatus(String documentTypeName,
                                  Person user,
                                  String appDocStatus,
                                  int expected,
                                  long changed)
- Verifies the DocumentSearchService finds documents with a given app document status
 
- 
- Parameters:
- documentTypeName- the doc type
- user- user for lookup
- appDocStatus- the app doc status target
- expected- the expected number of results
- changed- the time the transition occurred (used for from/to range)
 
assertAppDocStatuses
protected void assertAppDocStatuses(String documentId,
                                    String[] appDocStatuses)
- Verifies the document application document status history
 
- 
- Parameters:
- documentId- the doc id
- appDocStatuses- list of app doc statuses in chronological order
 
Copyright © 2005-2012 The Kuali Foundation. All Rights Reserved.