com.atlassian.confluence.it
Class ServerStateManager

java.lang.Object
  extended by com.atlassian.confluence.it.ServerStateManager

public class ServerStateManager
extends java.lang.Object

High-level manager for manipulating server state before and after acceptance tests.

Since:
v4.2

Constructor Summary
ServerStateManager(ConfluenceRpc rpc, TestData testData)
           
 
Method Summary
 void createTestData()
           
 DirectoryConfiguration getDirectoryConfiguration()
           
 UserManagementHelper getUserHelper()
           
 void removeTestData()
          Removes all test data, including users, groups, permission, spaces and content.
 void resetTestData()
          Resets all test data, including users, groups, permission, spaces, content, etc, to a stable state.
 void waitForUpgradeTasks()
          We need to wait for plugin upgrade tasks to complete before removing test data as it can break things.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServerStateManager

public ServerStateManager(ConfluenceRpc rpc,
                          TestData testData)
Method Detail

getUserHelper

public UserManagementHelper getUserHelper()

getDirectoryConfiguration

public DirectoryConfiguration getDirectoryConfiguration()

resetTestData

public void resetTestData()
Resets all test data, including users, groups, permission, spaces, content, etc, to a stable state. Called from every test setUp.


waitForUpgradeTasks

public void waitForUpgradeTasks()
We need to wait for plugin upgrade tasks to complete before removing test data as it can break things. Plugin builds which usually run upgrade tasks on test data can start running tests even before the upgrade tasks have finished


removeTestData

public void removeTestData()
Removes all test data, including users, groups, permission, spaces and content. If possible, call resetTestData() instead to create common data at the same time.


createTestData

public void createTestData()


Copyright © 2003-2014 Atlassian. All Rights Reserved.