org.hackystat.sensorbase.test
Class SensorBaseRestApiHelper

java.lang.Object
  extended by org.hackystat.sensorbase.test.SensorBaseRestApiHelper
Direct Known Subclasses:
TestCompressRestApi, TestIndexRestApi, TestPingRestApi, TestProjectMembershipRestApi, TestProjectRestApi, TestProjectSpectatorRestApi, TestProjectUriPatterns, TestRowCountRestApi, TestSdtRestApi, TestSensorDataRestApi, TestUsersRestApi

public class SensorBaseRestApiHelper
extends java.lang.Object

Provides helpful utility methods to SensorBase test classes, which will normally want to extend this class.

Author:
Philip Johnson

Field Summary
protected static java.lang.String adminEmail
          The admin email.
protected static java.lang.String adminPassword
          The admin password.
protected static ProjectManager projectManager
          Make a Manager available to this test class.
protected static SdtManager sdtManager
          Make a Manager available to this test class.
protected static SensorDataManager sensorDataManager
          Make a Manager available to this test class.
protected static Server server
          The SensorBase server used in these tests.
protected static UserManager userManager
          Make a Manager available to this test class.
 
Constructor Summary
SensorBaseRestApiHelper()
           
 
Method Summary
protected static java.lang.String getHostName()
          Returns the hostname associated with this test server.
static void setupServer()
          Starts the server going for these tests.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

server

protected static Server server
The SensorBase server used in these tests.


sensorDataManager

protected static SensorDataManager sensorDataManager
Make a Manager available to this test class.


userManager

protected static UserManager userManager
Make a Manager available to this test class.


sdtManager

protected static SdtManager sdtManager
Make a Manager available to this test class.


projectManager

protected static ProjectManager projectManager
Make a Manager available to this test class.


adminEmail

protected static java.lang.String adminEmail
The admin email.


adminPassword

protected static java.lang.String adminPassword
The admin password.

Constructor Detail

SensorBaseRestApiHelper

public SensorBaseRestApiHelper()
Method Detail

setupServer

public static void setupServer()
                        throws java.lang.Exception
Starts the server going for these tests.

Throws:
java.lang.Exception - If problems occur setting up the server.

getHostName

protected static java.lang.String getHostName()
Returns the hostname associated with this test server.

Returns:
The host name, including the context root.