In our previous blog, we learned how Easy Repro could help you automate Dynamics 365 in the most efficient way and the benefits that can be achieved if we opt to use EasyRepro instead of creating a test automation framework from scratch.
So, buckle up your seatbelts and get ready because, in this blog, we will see how we can get started using EasyRepro – and what are the prerequisites we need to fulfill before customizing in EasyRepro.
Cloning the EasyRepro Framework:
- Navigate to Microsoft EasyRepro Repository on Github:
You can have a look at all the system requirements, supported operating systems, and browsers. Moreover, you can learn about the supported CRM versions and what functionalities of CRM you can automate and which you cannot. We can also investigate the release versions of the framework for the information purposes.
2. Now click the “Code” button present and click the “Download ZIP” button
3. Extract Zip folder
Opening the UI Automation Solution:
- Now open the extracted files’ folder and look for a solution file named “UIAutomation.sln” and open that in Visual studio.
2. Reviewing the projects in the solution:
There are four projects in the solution. To develop a clear understanding of the framework, let's first discuss these projects in detail. This is an important aspect and requires you to have exact knowledge of the system. Otherwise, you will be wasting most of your time wandering in different projects looking for your required functions. So, let us discuss the projects which are available for us.
This project shows you how to write your tests. If you are new to EasyRepro, then you must go through this project to have a better understanding of the code structure and how you can use it to cater your testing needs.
This project helps us to communicate with web driver (Browser) and other under the hood components.
This is the project specifically used for Unified Interface and contains all the methods for that.
This project also contains the methods which can help us in automating Microsoft Dynamics CRM.
Getting Started with Sample Project:
Now since we have grasped the overall understanding of different projects which are available to us in EasyRepro. Now, let’s execute a sample test to get a clear picture of things:
- From the “Solution Explorer”, click on the Micosoft.Dynamics365.UIAutomation.Sample project and expand it. Now you will see a app.config file. Click on it to open the config file.
2. In the config file, under the <AppSettings>, enter the URL of the CRM system you want to run your test on and enter its login credentials to log in the CRM system.
3. Once you have made the above-mentioned changes. Click the Save button and right click on the “UIAutomation” solution. Now click on the “Build Solution” to build the solution.
4. Once you have built the solution, its time to execute the sample test case. To do so, navigate to the Test Explorer by clicking on the Test in the Visual Studio header over your mouse on Windows and then finally click on “Test Explorer.”
5. Now from Test Explorer, right click on the test of your choice and click the “Run Selected Tests” button and voila your test will run successfully. Now you can automate any functionality you desire by using the same way.
In this blog, we have learned how to get started on an EasyRepro framework and run tests using the sample project. Our next blog will discuss how we can create custom-designed tests of our choice using EasyRepro.