Mock Process Variable

Verb: mockProcessVariable

Simulates a variable from a process created by Mock Process, referring to an orchestration context in IBM Robotic Process Automation Studio, so that it is possible to run tests on commands that need a configured Orchestrator.

In a real context, the orchestrator variable would be configured in Web Client.

Syntax

mockProcessVariable --name(String) --type(WdgDatabaseTypesComboBox) [--value(String)]

Inputs

Script Designer Required AcceptedTypes Description
--name Name Required Text Name of the variable supposedly created in the orchestration context process.
--type Type Required WdgDatabaseTypesComboBox Type of the variable to be simulated. Options:
  • Boolean
  • Date and Time
  • Number
  • Text
  • --value Value Optional Text Variable value according to the type defined in the Type parameter.

    Example

    The Mock Process Variable command creates a simulated variable for a fictional orchestration context process, which is terminated after this creation. Then, the current message from the queue is obtained and the created variable is mapped. Finally, Log Message records the values ​​obtained from the simulated process.

    defVar --name queueName --type String --value "Simulated queue name"
    defVar --name queueStructure --type String --value "Simulated queue structure"
    defVar --name variableContent --type String --value "IBM Robotic Process Automation Simulate Orchestrator"
    defVar --name variableReceives --type String
    defVar --name successGet --type Boolean
    mockProcess --queuename "${queueName}" --body "${queueStructure}Simulated queue message structure."
    mockProcessVariable --name variableName --type "Text" --value "${variableContent}"
    endMockProcess
    currentQueueMessage queueName=queuename queueStructure=body successGet=success
    mapProcessVariables --mappings "variableName=${variableReceives}"
    logMessage --message "Queue name obtained: ${queueName}\r\nQueue structure obtained: ${queueStructure}\r\nGet current message success: ${successGet}\r\nMapped variable content: ${variableContent}\r\n" --type "Info"
    // Result:
    // Queue name obtained: Simulated queue name
    // Queue structure obtained: Simulated queue structure
    // Get current message success: True
    // Mapped variable content: IBM Robotic Process Automation Simulate Orchestrator
    

    Remarks

    This command must be used between the commands Mock Process and End Mock Process.

    See Also

  • Active MQ connection
  • Connect to Azure Storage
  • Connection to Queue Server System
  • Delete Queue
  • End Mock Process
  • Get Current Message from Queue
  • Get Queue
  • IBM MQ Connection
  • JMS MQ Connection
  • List Queues
  • Microsoft MQ Connection
  • Mock Process
  • MQ SQL Connection
  • Rabbit MQ Connection