nl.surfnet.coin.mock
Class AbstractMockHttpServerTest

java.lang.Object
  extended by nl.surfnet.coin.mock.AbstractMockHttpServerTest

public abstract class AbstractMockHttpServerTest
extends Object

Tests subclassing AbstractMockHttpServerTest can communicate with a mock Http endpoint that behavious like a real server. The idea behind this class is that http responses can be tested (regardless of the input request).


Constructor Summary
AbstractMockHttpServerTest()
           
 
Method Summary
protected  void setResponseResource(org.springframework.core.io.Resource responseResource)
          Set the expected response on the Handler
protected  void setResponseResource(org.springframework.core.io.Resource[] responseResource)
          Set the expected response on the Handler
protected  void setStatus(int status)
           
static void startServer()
           
static void stopServer()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractMockHttpServerTest

public AbstractMockHttpServerTest()
Method Detail

startServer

public static void startServer()

stopServer

public static void stopServer()

setResponseResource

protected void setResponseResource(org.springframework.core.io.Resource responseResource)
Set the expected response on the Handler

Parameters:
responseResource - the resource of the file containing the xml response

setResponseResource

protected void setResponseResource(org.springframework.core.io.Resource[] responseResource)
Set the expected response on the Handler

Parameters:
responseResource - the resource of the file containing the xml response

setStatus

protected void setStatus(int status)


Copyright © 2012. All Rights Reserved.