org.mule.transport.servlet
Class RESTTestCase

java.lang.Object
  extended by org.mule.tck.junit4.AbstractMuleTestCase
      extended by org.mule.tck.junit4.AbstractMuleContextTestCase
          extended by org.mule.tck.junit4.FunctionalTestCase
              extended by org.mule.transport.servlet.RESTTestCase

public class RESTTestCase
extends FunctionalTestCase


Field Summary
 
Fields inherited from class org.mule.tck.junit4.AbstractMuleContextTestCase
callbackCalled, CLASSNAME_ANNOTATIONS_CONFIG_BUILDER, IGNORED_DOT_MULE_DIRS, LOCK_TIMEOUT, muleContext, RECEIVE_TIMEOUT, TEST_MESSAGE
 
Fields inherited from class org.mule.tck.junit4.AbstractMuleTestCase
DEFAULT_TEST_TIMEOUT_SECS, globalTimeout, logger, name, TEST_TIMEOUT_SYSTEM_PROPERTY
 
Constructor Summary
RESTTestCase()
           
 
Method Summary
protected  String getConfigResources()
           
protected  boolean isDisabledInThisEnvironment()
          If a simple call to the web service indicates that it is not responding properly, we disable the test case so as to not report a test failure which has nothing to do with Mule.
protected  boolean isFailOnTimeout()
          Indicates whether the test should fail when a timeout is reached.
 void testRest1ParamGet()
           
 void testRest1ParamPost()
           
 void testRest2ParamsGet()
           
 void testRest2ParamsPost()
           
 
Methods inherited from class org.mule.tck.junit4.FunctionalTestCase
clearFlowAssertions, getBuilder, getComponent, getComponent, getFlowConstruct, getFunctionalTestComponent, loadResource, loadResourceAsString, stopFlowConstruct, testFlow, testFlow
 
Methods inherited from class org.mule.tck.junit4.AbstractMuleContextTestCase
addBuilders, configureMuleContext, createMuleContext, createObject, createObject, disposeContext, disposeContextPerTest, doSetUp, doTearDown, getConfigurationResources, getSensingNullMessageProcessor, getStartUpProperties, getTestConnector, getTestEvent, getTestEvent, getTestEvent, getTestEvent, getTestEvent, getTestEvent, getTestEvent, getTestEventContext, getTestEventContext, getTestEventUsingFlow, getTestInboundEndpoint, getTestInboundEndpoint, getTestInboundEndpoint, getTestInboundEndpoint, getTestInboundEndpoint, getTestOutboundEndpoint, getTestOutboundEndpoint, getTestOutboundEndpoint, getTestOutboundEndpoint, getTestOutboundEndpoint, getTestService, getTestService, getTestService, getTestSession, getTestTransactedInboundEndpoint, getTestTransformer, getTriggerableMessageSource, getTriggerableMessageSource, initialiseObject, isDisposeContextPerClass, isGracefulShutdown, isStartContext, setDisposeContextPerClass, setStartContext, setUpMuleContext
 
Methods inherited from class org.mule.tck.junit4.AbstractMuleTestCase
clearExcludedFlag, clearRequestContext, createTestTimeoutRule, getTestHeader, getTestTimeoutSecs, getTimeoutSystemProperty, initializeMuleTest, isDisabledInThisEnvironment, isExcluded, isOffline, isTestIncludedInExclusionFile
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RESTTestCase

public RESTTestCase()
Method Detail

getConfigResources

protected String getConfigResources()
Specified by:
getConfigResources in class FunctionalTestCase

isFailOnTimeout

protected boolean isFailOnTimeout()
Description copied from class: AbstractMuleTestCase
Indicates whether the test should fail when a timeout is reached.

This feature was added to support old test cases that depend on 3rd-party resources such as a public web service. In such cases it may be desirable to not fail the test upon timeout but rather to simply log a warning.

Overrides:
isFailOnTimeout in class AbstractMuleTestCase
Returns:
true if it must fail on timeout and false otherwise. Default value is true.

isDisabledInThisEnvironment

protected boolean isDisabledInThisEnvironment()
If a simple call to the web service indicates that it is not responding properly, we disable the test case so as to not report a test failure which has nothing to do with Mule. see EE-947

Overrides:
isDisabledInThisEnvironment in class AbstractMuleTestCase
Returns:
true if the test class should not be run.

testRest1ParamPost

public void testRest1ParamPost()
                        throws Exception
Throws:
Exception

testRest2ParamsPost

public void testRest2ParamsPost()
                         throws Exception
Throws:
Exception

testRest1ParamGet

public void testRest1ParamGet()
                       throws Exception
Throws:
Exception

testRest2ParamsGet

public void testRest2ParamsGet()
                        throws Exception
Throws:
Exception


Copyright © 2003-2012 MuleSoft, Inc.. All Rights Reserved.