Class InputAction

java.lang.Object
org.citrusframework.actions.AbstractTestAction
org.citrusframework.actions.InputAction
All Implemented Interfaces:
Described, Named, TestAction, TestActorAware

public class InputAction extends AbstractTestAction
Test action prompts user data from standard input stream. The input data is then stored as new test variable. Test workflow stops until user input is complete. Action can declare a set of valid answers, so user will be prompted until a valid answer was returned.
  • Field Details

  • Constructor Details

  • Method Details

    • doExecute

      public void doExecute(TestContext context)
      Description copied from class: AbstractTestAction
      Subclasses may add custom execution logic here.
      Specified by:
      doExecute in class AbstractTestAction
    • getInputReader

      protected BufferedReader getInputReader()
      Provides input stream reader from system in standard input stream.
      Returns:
    • getMessage

      public String getMessage()
      Gets the message.
      Returns:
      the message
    • getVariable

      public String getVariable()
      Gets the variable.
      Returns:
      the variable
    • getValidAnswers

      public String getValidAnswers()
      Gets the validAnswers.
      Returns:
      the validAnswers