- Overview
- Callout
- Complex Scenarios
- Credentials
- Data Service
- About the Data Service activity package
- Project compatibility
- Create Entity Record (New)
- Update Entity Record (New)
- Delete Entity Record (New)
- Get Entity Record by Id (New)
- Query Entity Records (New)
- Upload File to Record Field (New)
- Download File from Record Field (New)
- Delete File from Record Field (New)
- Create Multiple Entity Records (New)
- Update Multiple Entity Records (New)
- Delete Multiple Entity Records (New)
- Form
- Release notes
- Project compatibility
- Real Time Forms
- Updating form data
- Running forms using JavaScript
- Customizing Forms Using CSS
- Conditional components
- Adding multiple components on the same row in Columns
- Using the Data Table component
- Get File/Folder path
- Reading cell values from a Data Grid component
- Displaying PDF files
- Displaying images in forms
- Scrolling through Data Grids
- Using Dev Tools with forms
- Calculate form component values
- Managing dates in forms
- Opening hyperlinks inside forms
- Displaying a default tab in forms
- Displaying the full label of a component
- Searching long strings in drop-down lists
- About the pre 23.4 Form experience
- Project Compatibility
- Real Time Forms
- Dynamic Checkboxes
- Conditional Dropdowns
- Displaying a Default Tab
- Displaying Images
- Displaying PDF Files
- Displaying the Full Label
- Dynamic HTML Elements
- Managing Dates
- Searching Long Strings in Drop-downs
- Customizing Forms Using Local CSS Files
- Executing Do Block On Checkbox Change
- Customizing Columns Width
- Updating Form Data
- Resetting Collection Data
- Advanced Logic
- Executing Do Block on Dropdown Option Change
- Reading Cell Values From a Data Grid Component
- Conditional Components
- Scrolling Through Data Grid Components
- Using the Grid Component
- Dev Tools
- Calculated Value
- Dynamic Dropdowns
- Switching Tabs With Button Click
- Opening Hyperlinks Inside Form
- FTP
- IPC
- Persistence
- Release notes
- Project compatibility
- About the Persistence activity package
- Bulk Form Designer
- Start Job And Get Reference
- Wait For Job And Resume
- Add Queue Item And Get Reference
- Wait For Queue Item And Resume
- Wait For Form Task And Resume
- Resume After Delay
- Assign Tasks
- Create External Task
- Wait For External Task And Resume
- Complete Task
- Forward Task
- Get Form Tasks
- Get Task Data
- Get App Tasks
- Add Task Comment
- Update Task Labels
- Create App Task
- Wait For App Task And Resume
- Configure task timer
- Working with App tasks
- Building Your First Form Action
- Advanced Controls for Drop-downs
- Embedding Objects in Form Actions
- Allowing Users to Upload Files to the Storage Bucket
- Adding Advanced Logic Using Java Script
- Setting a Default Tab
- Removing the Delete button from Edit Grid using custom CSS
- Customizing Edit Grid templates
- Using buttons to trigger custom logic
- Using an External Form Layout
- Dynamically expanding form components at runtime
- Aligning the content of a form component from left to right using JSON attributes
- Sample Workflows
- Automation Ops Pipelines
- System
- Release notes
- About the System activity package
- Project compatibility
- Supported character encoding
- RegEx Builder Wizard
- Add Data Column
- Add Data Row
- Add Log Fields
- Add or Subtract from Date
- Add Transaction Item
- Add Queue Item
- Append Item to Collection
- Append Item to List
- Append Line
- Beep
- Break / Exit Loop
- Browse for File
- Browse for Folder
- Build Collection
- Build Data Table
- Bulk Add Queue Items
- Change Case for Text
- Change Type
- Check False
- Check True
- Clear Data Table
- Collection to Data Table
- Comment
- Compress/Zip Files
- Copy File
- Copy Folder
- Combine text
- Comment Out / Disabled Activities
- Continue / Skip Current
- Create File
- Create Folder
- Create List
- Custom Input
- Delete
- Delete File
- Delete Folder
- Delete Storage File
- Delete Queue Items
- Disable Local Trigger
- Do While
- Download file from URL
- Download Storage File
- Enable Local Trigger
- Evaluate Business Rule
- Exists in Collection
- Extract/Unzip Files
- Extract Date and Time from Text
- Extract Text
- File Change Trigger
- File Exists
- Filter Collection
- Filter Data Table
- Folder Exists
- For Each
- For Each File in Folder
- File Change Trigger V3
- Find and Replace
- Find Matching Patterns
- For Each Folder in Folder
- For Each Row in Data Table
- Format Date as Text
- Format Value
- Generate Data Table From Text
- Get Asset
- Get Credential / Get Orchestrator Credential
- Get Current Job Info
- Get Environment Folder
- Get Environment Variable
- Get File Info
- Get Folder Info
- Get Jobs
- Get Processes
- Get Row Item
- Get Transaction Item
- Get Username/Password
- Get Queue Items
- Global Variable Changed Trigger
- Input Dialog
- Invoke Code
- Invoke Com Method
- Invoke Power Shell
- Invoke Process
- Invoke VBScript
- Invoke Workflow File
- Is Text Matching
- Join Data Tables
- Kill Process
- Launch Workflow Interactive
- List Storage Files
- Log Message
- Lookup Data Table
- Manual Trigger
- Merge Collections
- Merge Data Table
- Message Box
- Modify Date
- Modify Text
- Move File
- Move Folder
- Multiple Assign
- New Item Added to Queue
- Notify Global Variable Changed
- Orchestrator HTTP Request
- Output Data Table
- Path Exists
- Postpone Transaction Item
- Process End Trigger
- Process Start Trigger
- Raise Alert
- Read List Item
- Read Text File
- Read Storage Text
- Remove Data Column
- Remove Data Row
- Remove Duplicate Rows
- Remove From Collection
- Remove Log Fields
- Replace Matching Patterns
- Repeat Number of Times
- Repeat Trigger
- Rename File
- Rename Folder
- Report Status
- Reset Timer
- Resume Timer
- Retry Scope
- Return
- Run Local Triggers
- Run Parallel Process
- Set Asset
- Set Credential
- Set Environment Variable
- Set Transaction Progress
- Set Transaction Status
- Should Stop
- Split Text
- Sort Data Table
- Start Timer
- Start Job
- Stop Job
- Stop Local Triggers
- Stop Timer
- Text to Left/Right
- Text to Upper/Lowercase
- Time Trigger
- Trigger Scope
- Timeout Scope
- Update Row Item
- Update List Item
- Upload Storage File
- Wait for Download
- Wait Queue Item
- While
- Workflow Placeholder
- Write Storage Text
- Write Text File
- AddDataRow
- AddQueueItem
- AddTransactionItem
- AppendLine
- BulkAddQueueItems
- ClearDataTable
- CompressZipFiles
- CopyFile
- CreateFile
- CreateFolder
- DeleteFileOrFolder
- DeleteQueueItems
- DeleteStorageFile
- DownloadStorageFile
- ExtractUnzipFiles
- FilterDataTable
- GetAsset
- GetCredential
- GetJobs
- GetQueueItem
- GetQueueItems
- GetResourceForLocalPath
- GetRowItem
- GetTransactionItem
- InvokeProcess
- JoinDataTables
- ListStorageFiles
- LookUpDataTable
- MergeDataTable
- MoveFile
- OrchestratorHTTPRequest
- OutputDataTable
- PathExists
- PostponeTransactionItem
- ReadStorageText
- ReadTextFile
- RemoveDataColumn
- RemoveDuplicateRows
- Replace
- SetAsset
- SetCredential
- SetTransactionProgress
- SetTransactionStatus
- SortDataTable
- StartJob
- StopJob
- UpdateRowItem
- UploadStorageFile
- WaitQueueItem
- WriteStorageText
- WriteTextFile
- Testing
- Release notes
- About the Testing activity package
- Project compatibility
- Project Settings
- Add Test Data Queue Item
- Address
- Attach Document
- Bulk Add Test Data Queue Items
- Create Comparison Rule
- Delete Test Data Queue Items
- Get Test Data Queue Item
- Get Test Data Queue Items
- Given Name
- Last Name
- Random Date
- Random Number
- Random String
- Random Value
- Verify Control Attribute
- Verify Documents Equivalence
- Verify Expression
- Verify Expression With Operator
- Verify Range
- Verify Text Equivalence
- Address
- AddTestDataQueueItem
- AttachDocument
- BulkAddTestDataQueueItems
- DeleteTestDataQueueItems
- GetTestDataQueueItem
- GetTestDataQueueItems
- GivenName
- LastName
- RandomDate
- RandomNumber
- RandomString
- RandomValue
- VerifyAreEqual
- VerifyAreNotEqual
- VerifyContains
- VerifyExpression
- VerifyExpressionWithOperator
- VerifyIsGreater
- VerifyIsGreaterOrEqual
- VerifyIsLess
- VerifyIsLessOrEqual
- VerifyIsRegexMatch
- VerifyRange
- Adding and consuming test data queue items
- Workflow Events
- Workflow Foundation
Workflow Activities
Adding and consuming test data queue items
This tutorial shows you how to work with the test data queue activities.
In the given scenario, we generate random values, add them as items to a test data queue, and use them to fill out loan application forms in the UiBank app. Let's break down the process that this tutorial guides you on:
- Generate the data used to fill in the
Apply for a loan form in the UiBank
app:
- Enter the number of test data queue items you want to add.
- Generate the necessary random values for a loan application.
- Add these values as items to a test data queue.
- Retrieve the items from the test data queue and use them to fill in the form:
- Retrieve these items from the test data queue.
- Use these items to fill in the Apply for a loan form in the UiBank app with the help of UIAutomation activities.
- The Test Automation module in Orchestrator, used as the Testing tab.
- Testing.Activities
- UIAutomation.Activities
- System.Activities
Start by deciding the number of items you want to add to the test data queue. For each item generate random values for various parameters such as first name, last name, age, yearly income, and loan amount.
- Create a test data queue in
Orchestrator. Go to the Testing tab, select Test Data Queues, and
create a queue called
TMDTQueue
. - Open your project in Studio and create a new Workflow. Name it
GenerateLoanData
. - Add an Input Dialog activity with the following settings:
- Input Label:
"Records"
. - Dialog Title:
"Enter the records"
. - Input Type: Text Box.
- In the Value entered field, create a variable for saving the
number of records entered. For this example, name the variable
records_new
.
- Input Label:
- Add an Assign activity to
convert the string variable you previously created to
Int32
. Create anInt32
variable namedcount
and assign it the following expression:Convert.ToInt32(records_new)
. - Add another Assign
activity to initialize a counter. Create an
Int32
variable callednumRec
and assign it the value1
. It acts as your counter for the upcoming While loop.
- Add a While activity and set the Condition as
numRec <= count
. This ensures that the loop executes as long asnumRec
is less than or equal tocount
. - Add a Try Catch activity within the While loop. This helps managing any errors during execution.
- Inside the Try block, add activities to generate random first name, last
name, loan amount, age, yearly income, and loan term.
- Use the Given Name
activity to generate a random first name. Store the generated value
within a variable named
firstName
. - Use the Last Name
activity to generate a random last name. Store the generated value
within a variable named
lastName
. - Use four Random Number
activities to generate random
Decimal
values for parameters like loan amount, age, yearly income, and loan term.Parameter Min value Max value Output variable Loan amount 5000
100000
loanAmount
Age 18
100
age
Yearly income 100000
1000000
yearlyIncome
Loan term 5
5
loanTerm
- Use the Given Name
activity to generate a random first name. Store the generated value
within a variable named
- Add an Assign activity to
generate an email address based on the first names and last names generated
previously. Within a
String
variable (namedemail
), save the following value:firstName+lastName+"@gmail.com"
. - Add an Add Test Data Queue Item
activity to add the generated values as items into the queue.
- Input a Queue Name. For this example, input
TDMTQueue
. - In the Items dictionary, add key-value pairs for each parameter
generated previously. The value for each pair will be the variable where
you store the corresponding generated value. For this example, add the
following key-value pairs:
Key Type Value loanAmount System.Decimal
loanAmount
age System.Decimal
age
yearlyIncome System.Decimal
yearlyIncome
email String
email
term System.Decimal
term
id Int32
idInteger
firstName String
firstName
lastName String
lastName
- Input a Queue Name. For this example, input
- Add an Assign activity to
increment the counter variable value by 1:
numRec = numRec + 1
.
Now let's use the random values stored in the queue to fill out a loan application form in the UiBank app.
- Create another Workflow within your Studio project. Name it
LoanApplication
. - Add an Get Test Data Queue Item activity to
retrieve the queue items you previously added. Provide the same Queue
Name. For this example, input
TDMTQueue
and save the queue items within aDictionary(<String,Object>)
variable, nameddata
. - Add Assign activities to
store the values you want to retrieve from the queue items. For this example,
add five activities, for the following values: email, loan amount, term, yearly
income, and age. Make sure each value corresponds to its key in the
data
dictionary.Save to Value to save email
data.Item("email")
loanAmount
data.Item("loanAmount")
term
data.Item("term")
yearlyIncome
data.Item("yearlyIncome")
age
data.Item("age")
- Add an Use Application/Browser activity to
automate the UiBank app. In the browser URL field input
the login page of the UiBank app:
"https://uibank.uipath.com/welcome"
.- Add two Type Into activities, to insert the username and password. Input your credentials as plain text.
- Use a series of Click activities to automate
the following:
- Click the Sign in button.
- Consent to the Privacy Policy by clicking I agree.
- Navigate to the loan application form by clicking Products, then Loans, and lastly, Apply for a Loan.
- Add five Type Into
activities to input the test data queue values. Use the
.toString
method because these fields only acceptString
variables. - Lastly, add a Click activity, to click the Submit Loan Application button.
To follow the steps of this tutorial and try it out yourself, download the following sample project: TestDataQueuesActivitiesSample.