Pages

Friday, January 2, 2015

STEP #3 Add Controls to UIMap1.uitest - this is a partial class so the generated code will be added to UIMap1.Designer.cs and we'll add custom code to UIMap1.cs

Load IE and browse to Amazon.com
Go back to Visual Studio, right click UIMap1.uitest and select “Edit with Coded UI Test Builder” and the builder loads in the lower right corner with Amazon.com open in IE

Left click and hold down the Cross Hair button, then drag to highlight the control to be added to the UI Map

Click the double arrow in top left corner and the UIMap is displayed

Click button in upper left corner to add the control to the map

The checkmarks turn dark gray but the UIMap has not been updated yet

Click the Generate code button to add controls to the map

You are prompted that there are no code changes except updates to the UIMap

Click Generate button and close the builder to return to Visual Studio
Double click UIMap1.Designer.cs and search for the control that was added - This tells you which properties the tool uses to identify the control on the page

UIMap1.Designer.cs contains the generated code that gets overwritten each time the solution is built





No comments: