Interface RestServer

All Known Implementing Classes:
RestServerImpl

public interface RestServer
This interface represents a server which offers a Crowd REST service.

Tests retrieve RestServer instance by calling com.atlassian.crowd.acceptance.tests.rest.RestServerImpl.INSTANCE

  • Method Summary

    Modifier and Type
    Method
    Description
    void
    This method is called after each test is run, and it should free resources.
    void
    before(Class testClass, String testName)
    This method is called before each test is run, and it should reset the server in a predictable state.
    javax.ws.rs.client.Client
    decorateClient(javax.ws.rs.client.Client client)
    Perform custom processing on the Jersey client, such as adding any necessary headers for multitenant tests.
  • Method Details

    • before

      void before(Class testClass, String testName) throws Exception
      This method is called before each test is run, and it should reset the server in a predictable state.
      Parameters:
      testClass - the class containing the currently ran test
      testName - the name of the test method
      Throws:
      Exception - if the server could not be restored
    • after

      void after()
      This method is called after each test is run, and it should free resources.
    • decorateClient

      javax.ws.rs.client.Client decorateClient(javax.ws.rs.client.Client client)
      Perform custom processing on the Jersey client, such as adding any necessary headers for multitenant tests.
      Parameters:
      client - The client to decorate
      Returns:
      The decorated client