org.hackystat.sensorbase.resource.sensordatatypes
Class TestSdtRestApi

java.lang.Object
  extended by org.hackystat.sensorbase.test.SensorBaseRestApiHelper
      extended by org.hackystat.sensorbase.resource.sensordatatypes.TestSdtRestApi

public class TestSdtRestApi
extends SensorBaseRestApiHelper

Tests the SensorBase REST API for both the SensorDataTypes and SensorDataType resources.

Author:
Philip M. Johnson

Field Summary
 
Fields inherited from class org.hackystat.sensorbase.test.SensorBaseRestApiHelper
adminEmail, adminPassword, projectManager, sdtManager, sensorDataManager, server, userManager
 
Constructor Summary
TestSdtRestApi()
           
 
Method Summary
 void getSdt()
          Test that GET host/sensorbase/sensordatatypes/TestSdt returns the TestSdt SDT.
 void getSdtIndex()
          Test that GET host/sensorbase/sensordatatypes returns an index containing TestSDT, and that all SDTs in the index can be retrieved.
 void putSdt()
          Test that PUT and DELETE host/sensorbase/sensordatatypes/TestSdt are OK.
 
Methods inherited from class org.hackystat.sensorbase.test.SensorBaseRestApiHelper
getHostName, setupServer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestSdtRestApi

public TestSdtRestApi()
Method Detail

getSdtIndex

public void getSdtIndex()
                 throws java.lang.Exception
Test that GET host/sensorbase/sensordatatypes returns an index containing TestSDT, and that all SDTs in the index can be retrieved.

Throws:
java.lang.Exception - If problems occur.

getSdt

public void getSdt()
            throws java.lang.Exception
Test that GET host/sensorbase/sensordatatypes/TestSdt returns the TestSdt SDT.

Throws:
java.lang.Exception - If problems occur.

putSdt

public void putSdt()
            throws java.lang.Exception
Test that PUT and DELETE host/sensorbase/sensordatatypes/TestSdt are OK. Note that these operations require admin authentication.

Throws:
java.lang.Exception - If problems occur.