We all know that Power Automate is an excellent way of
automating business processes within your business but did you know that you
are also able to use it as a way of continuously testing?
Power Automate has recently released the concept of UI Flows
which allow flows to interact with a browser using the Selenium framework. This
provides a very efficient way to implement automated testing into your
organisation. In this blog, I will show you how to create a flow that creates
an Account in your CRM instance.
|Flow Subscription that included premium features.|
|A device that runs Windows 10, Windows Server 2016, or Windows Server 2019.|
|You will require Google Chrome or Edge Chromium.|
|Download and Install the UI Flow Installer: https://go.microsoft.com/fwlink/?linkid=2102613|
|Download and Install Selenium IDE: https://go.microsoft.com/fwlink/?linkid=2107665|
- Flow Subscription that included premium features.
- A device that runs Windows 10, Windows Server 2016, or Windows Server 2019.
- You will require Google Chrome or Edge Chromium.
- Download and Install the UI Flow. Installer: https://go.microsoft.com/fwlink/?linkid=2102613
- Download and Install Selenium IDE: https://go.microsoft.com/fwlink/?linkid=2107665
- Non-US (QWERTY) keyboards are not supported in the preview release, playback of an input step where the key sequence was recorded from a non-US (QWERTY) keyboard will result in keystrokes in US (QWERTY).
Desktop UI Flows
- Multiple monitors
- Virtual machines
- Double click, mouse hover, touch/pen input
- Interactions on Windows (File explorer, startup menu, taskbar, etc.)
Web UI Flows
- User session information (e.g., cookies) will not be reused during playback. You will have to edit the script to embed sign-in information when required by websites.
Let’s get started creating a new UI Flow.
Login to https://flow.microsoft.com
Navigate to My Flows from the menu on the left-hand side.
Select UI Flow (Preview)
Select Crete a UI Flow.
You will then be presented with two options.
You need to select the correct option depending on the type of action that you wish to automate.
Desktop App: Example: if I want to automate customer creation in a custom access database.
Web App: Example: if I want to automate account creation in Dynamics 365 Customer Engagement.
In this example, we will be using the Web app.
You will be prompted for Name and a Base URL for the web application you wish to test.
In this example, I have entered a name to identify my CRM instance and the URL in full of the particular model-driven app that I wish to test.
You can then select Launch Recorder.
This will open up the Selenium steps recorder.
You then select REC in the top right-hand side of the Selenium IDE, and it will begin the recording process.
You then go through the process of creating a new account within CRM and Selenium will record each of the steps that you have taken. When you have finished push the stop button at the top right-hand side of the Selenium IDE window.
You can now see all of the steps within your test.
You can now save your project.
You are now able to see the UI flow under My Flows.
You have now created your first UI flow. In the next instalment, I will explain how to run your UI flows again and create and automate your testing.
About the Author:
Hey! I am Dave Burrell a Power Platform Solution Architect. I am an evangelist for all things Power Platform and love nothing more than a #LowCodeNoCode implementation.
Burrell, D. (2020). POWER AUTOMATE: Your UI Testing Companion – Part 1. Available at: https://daveburrell.co.uk/power-automate-your-ui-testing-companion-part-1/ [Accessed: 24th March 2020].
Find more great Power Platform content here.