170 likes | 304 Views
Sofia Event Center 14-15 May 2014. Test Automation with Visual Studio. Martin Kulov. Coded UI Features. Functional Testing Code generation Intent aware recording and resilient playback Test Automation Local and Remote Data collectors Rich Extensibility. Recording.
E N D
Sofia Event Center 14-15 May 2014 Test Automation with Visual Studio Martin Kulov
Coded UI Features • Functional Testing • Code generation • Intent aware recording and resilient playback • Test Automation • Local and Remote Data collectors • Rich Extensibility
Recording • Goal oriented implementation • Typing text • Searching for result • Clicking a button • Launching an app
Playback • Fail safe implementation • Search for control based on ID • Wait for control to get ready • Ensure control is visible and shown • Ensure action is executed
Creating Coded UI Test • Microsoft Test Manager • From existing recoding • From scratch using Coded UI Test Builder • Writing Coded UI plugin
Search Methods • SearchProperties – Must have properties • FilterProperties – limits results from Search to only one match
Data Collectors • Event Log • IntelliTrace • System Information • Video Recorder • Custom Collectors
Coded UI Test Editor • Clean up UI actions • Renaming of test methods and controls • Split action in multiple methods • Pause action • Find location of the control
Asserts • AreEqual • AreNotEqual • AreSame • Fail • Inconclusive • IsFalse / IsTrue • IsInstanceOfType / IsNotInstanceOfType • IsNotNull / IsNull
Data Sources • MTM Test Case • XML • CSV • XSL • SQL Express
Multiple UIMaps • Applicable for larger apps • New UIMap for each page or module • Each UIMap can be assigned to different tester • Easier to maintain
PlaybackSettings class • Playback.Wait • Continue on Error
Playback.Wait • WaitForReadyControl() – Waits to get ready to accept mouse/keyboard input • WaitForControEnabled() – Waits the control to be enabled • WaitForControlExisted() – Waits the control to exist on the UI
Questions??? Share your feedback for this particular session and for the overall conference experience at http://aka.ms/intouch for a chance to win our prizes!