Tabnine Logo
RoutingService.setOperationMode
Code IndexAdd Tabnine to your IDE (free)

How to use
setOperationMode
method
in
com.epam.wilma.router.RoutingService

Best Java code snippets using com.epam.wilma.router.RoutingService.setOperationMode (Showing top 9 results out of 315)

origin: epam/Wilma

@Override
protected void doGet(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException {
  logger.info(urlAccessLogMessageAssembler.assembleMessage(req, "Set Operation Mode: STUB."));
  proxyModeToggle.switchProxyModeOff();
  routingService.setOperationMode(OperationMode.STUB);
}
origin: epam/Wilma

@Override
protected void doGet(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException {
  logger.info(urlAccessLogMessageAssembler.assembleMessage(req, "Set Operation Mode: PROXY."));
  proxyModeToggle.switchProxyModeOn();
  routingService.setOperationMode(OperationMode.PROXY);
}
origin: epam/Wilma

@Override
protected void doGet(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException {
  logger.info(urlAccessLogMessageAssembler.assembleMessage(req, "Set Operation Mode: WILMA (proxy+stub)."));
  proxyModeToggle.switchProxyModeOff();
  routingService.setOperationMode(OperationMode.WILMA);
}
origin: epam/Wilma

@Test
public void testDoGetShouldSetOpModeAndToggleInRoutingService() throws ServletException, IOException {
  //GIVEN
  OperationMode operationMode = OperationMode.PROXY;
  //WHEN
  underTest.doGet(request, response);
  //THEN
  verify(routingService).setOperationMode(operationMode);
}
origin: epam/Wilma

@Test
public void testDoGetShouldSetOpModeAndToggleInRoutingService() throws ServletException, IOException {
  //GIVEN
  OperationMode operationMode = OperationMode.STUB;
  //WHEN
  underTest.doGet(request, response);
  //THEN
  verify(routingService).setOperationMode(operationMode);
}
origin: epam/Wilma

@Test
public void testDoGetShouldSetOpModeAndToggleInRoutingService() throws ServletException, IOException {
  //GIVEN
  OperationMode operationMode = OperationMode.WILMA;
  //WHEN
  underTest.doGet(request, response);
  //THEN
  verify(routingService).setOperationMode(operationMode);
}
origin: epam/Wilma

@Test
public void testSetOperationModeShouldSetProxyMode() {
  //GIVEN
  operationMode = OperationMode.PROXY;
  given(configurationAccess.getProperties()).willReturn(properties);
  given(properties.getOperationMode()).willReturn(operationMode);
  //WHEN
  underTest.setOperationMode(operationMode);
  //THEN
  OperationMode result = (OperationMode) Whitebox.getInternalState(underTest, "operationMode");
  Assert.assertEquals(result, operationMode);
}
origin: epam/Wilma

@Test
public void testSetOperationModeShouldSetStubMode() {
  //GIVEN
  operationMode = OperationMode.STUB;
  given(configurationAccess.getProperties()).willReturn(properties);
  given(properties.getOperationMode()).willReturn(operationMode);
  //WHEN
  underTest.setOperationMode(operationMode);
  //THEN
  OperationMode result = (OperationMode) Whitebox.getInternalState(underTest, "operationMode");
  Assert.assertEquals(result, operationMode);
}
origin: epam/Wilma

@Test
public void testSetOperationModeShouldSetWilmaMode() {
  //GIVEN
  operationMode = OperationMode.WILMA;
  given(configurationAccess.getProperties()).willReturn(properties);
  given(properties.getOperationMode()).willReturn(operationMode);
  //WHEN
  underTest.setOperationMode(operationMode);
  //THEN
  OperationMode result = (OperationMode) Whitebox.getInternalState(underTest, "operationMode");
  Assert.assertEquals(result, operationMode);
}
com.epam.wilma.routerRoutingServicesetOperationMode

Javadoc

Sets the new operation mode.

Popular methods of RoutingService

  • performModification
    This method execute the given command. The given command is any operation which works with the stubD
  • getStubDescriptors
  • getResponseDescriptorDTOAndRemove
    Reads a value matched to a key from the response descriptor map and if the value is found it deletes
  • isStubModeOn
  • redirectRequestToStub
    Redirects requests based on their content. If a request needs to be redirected to the stub, it will
  • getOperationMode
  • saveInResponseDescriptorMap

Popular in Java

  • Reading from database using SQL prepared statement
  • setContentView (Activity)
  • setRequestProperty (URLConnection)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • Menu (java.awt)
  • OutputStream (java.io)
    A writable sink for bytes.Most clients will use output streams that write data to the file system (
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now