eu.scape_project.watch.rest
Class CoreRestTest

java.lang.Object
  extended by com.sun.jersey.test.framework.JerseyTest
      extended by eu.scape_project.watch.rest.CoreRestTest

public class CoreRestTest
extends com.sun.jersey.test.framework.JerseyTest

Unit tests of the watch core REST API.

Author:
Luis Faria

Field Summary
 org.junit.rules.MethodRule watchman
          Logging start and finish of tests.
 
Constructor Summary
CoreRestTest()
          Initialize Jersey Test Framework.
 
Method Summary
static void afterClass()
          Cleanup the data folder.
 void asyncRequest(eu.scape_project.watch.rest.WatchClient.Format format)
          Tests on asynchronous requests.
 void asynRequestJSON()
          Tests on asynchronous requests with JSON output.
 void asynRequestXML()
          Tests on asynchronous requests with XML output.
static void beforeClass()
          Initialize the data folder.
 void entityCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
          Test Entity CRUD operations.
 void entityCrudJSON()
          Test Entity CRUD operations with JSON output.
 void entityCrudXML()
          Test Entity CRUD operations with XML output.
 void entityTypeCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
          Test Entity Type CRUD operations.
 void entityTypeCrudJson()
          Test entity type with JSON output.
 void entityTypeCrudXML()
          Test entity type with XML output.
 void propertyCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
          Test Property CRUD operations.
 void propertyCrudJSON()
          Test Property CRUD operations using JSON output format.
 void propertyCrudXML()
          Test Property CRUD operations using XML output format.
 void propertyValueCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
          Test PropertyValue CRUD operations.
 void propertyValueCrudJSON()
          Test PropertyValue CRUD operations using JSON output format.
 void propertyValueCrudXML()
          Test PropertyValue CRUD operations using XML output format.
 void setUp()
           
 void syncRequest(eu.scape_project.watch.rest.WatchClient.Format format)
          Tests on synchronous requests.
 void synRequestJSON()
          Tests on synchronous requests with JSON output.
 void synRequestXML()
          Tests on synchronous requests with XML output.
 
Methods inherited from class com.sun.jersey.test.framework.JerseyTest
client, configure, getBaseURI, getClient, getClientFactory, getPort, getTestContainerFactory, resource, setClientFactory, setTestContainerFactory, tearDown
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

watchman

public org.junit.rules.MethodRule watchman
Logging start and finish of tests.

Constructor Detail

CoreRestTest

public CoreRestTest()
Initialize Jersey Test Framework.

Method Detail

beforeClass

public static void beforeClass()
Initialize the data folder.


afterClass

public static void afterClass()
Cleanup the data folder.


setUp

public void setUp()
           throws Exception
Overrides:
setUp in class com.sun.jersey.test.framework.JerseyTest
Throws:
Exception

entityTypeCrudJson

public void entityTypeCrudJson()
Test entity type with JSON output.

See Also:
entityCRUD(eu.scape_project.watch.rest.WatchClient.Format)

entityTypeCrudXML

public void entityTypeCrudXML()
Test entity type with XML output.


entityTypeCRUD

public void entityTypeCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
Test Entity Type CRUD operations.

Parameters:
format - The output format.

entityCrudJSON

public void entityCrudJSON()
Test Entity CRUD operations with JSON output.

See Also:
entityCRUD(eu.scape_project.watch.rest.WatchClient.Format)

entityCrudXML

public void entityCrudXML()
Test Entity CRUD operations with XML output.

See Also:
entityCRUD(eu.scape_project.watch.rest.WatchClient.Format)

entityCRUD

public void entityCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
Test Entity CRUD operations.

Parameters:
format - the output format

propertyCrudJSON

public void propertyCrudJSON()
Test Property CRUD operations using JSON output format.

See Also:
propertyCRUD(eu.scape_project.watch.rest.WatchClient.Format)

propertyCrudXML

public void propertyCrudXML()
Test Property CRUD operations using XML output format.

See Also:
propertyCRUD(eu.scape_project.watch.rest.WatchClient.Format)

propertyCRUD

public void propertyCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
Test Property CRUD operations.

Parameters:
format - The output format

propertyValueCrudJSON

public void propertyValueCrudJSON()
Test PropertyValue CRUD operations using JSON output format.

See Also:
propertyValueCRUD(eu.scape_project.watch.rest.WatchClient.Format)

propertyValueCrudXML

public void propertyValueCrudXML()
Test PropertyValue CRUD operations using XML output format.

See Also:
propertyValueCRUD(eu.scape_project.watch.rest.WatchClient.Format)

propertyValueCRUD

public void propertyValueCRUD(eu.scape_project.watch.rest.WatchClient.Format format)
Test PropertyValue CRUD operations.

Parameters:
format - The output format

synRequestXML

public void synRequestXML()
Tests on synchronous requests with XML output.


synRequestJSON

public void synRequestJSON()
Tests on synchronous requests with JSON output.


syncRequest

public void syncRequest(eu.scape_project.watch.rest.WatchClient.Format format)
Tests on synchronous requests.

Parameters:
format - The format of the output.

asynRequestXML

public void asynRequestXML()
Tests on asynchronous requests with XML output.


asynRequestJSON

public void asynRequestJSON()
Tests on asynchronous requests with JSON output.


asyncRequest

public void asyncRequest(eu.scape_project.watch.rest.WatchClient.Format format)
Tests on asynchronous requests.

Parameters:
format - The format of the output.


Copyright © 2012. All Rights Reserved.