1 / 156

Automating Coded UI Testing using Microsoft Testing Tools in Visual Studio 2012

Automating Coded UI Testing using Microsoft Testing Tools in Visual Studio 2012. Clive G Hermann. Introductions. Name Title/Function Job Responsibility Testing Experience C# Experience Expectations for the Course. Course Materials. Course Contents. Overview of Automated Code UI Testing

diallo
Download Presentation

Automating Coded UI Testing using Microsoft Testing Tools in Visual Studio 2012

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Automating Coded UI Testing using Microsoft Testing Tools in Visual Studio 2012 Clive G Hermann

  2. Introductions • Name • Title/Function • Job Responsibility • Testing Experience • C# Experience • Expectations for the Course

  3. Course Materials

  4. Course Contents • Overview of Automated Code UI Testing • Walkthrough steps from beginning-to-end • Creating Manual Tests • Creating a coded UI test Using Coded UI Test Builder • Automating Coded UI Test Cases • Introduction to Application Lifecycle Management (ALM) • Anatomy of Coded UI Tests • New Visual Studio 2012 ALM Features • Automating Coded UI Tests

  5. Course Contents2 • Data Driven Coded UI Tests • Anatomy of Code UI Tests • Introduction to Lifecycle Management • Extending Coded UI Tests and Action Recordings • Testing Large Applications with Multiple UI Maps • Using HTML5 Controls in Coded UI Tests • Visual Studio 2012 ALM Features • Upgrading Coded UI Tests from Visual Studio 2010

  6. Course Contents3 • Using WPF with Coded UI Tests • Best Practices for Coded UI Tests • Using the Coded UI Test Logs • Using SharePoint with Coded UI Tests • ExcelCodedUIHelper

  7. Overview of Automated Code UI Testing

  8. Reality of Automated Testing • 70% of all Testing is manual

  9. Code UI Tsting • Replacing a Manual User Interface Test • With a Automated User Interface Test • To Allow: • Replication • Consistency • Regression Testing For: • Multiple Environments • Multiple Versions

  10. 1) Overview of Automated Code UI Testing • UI Testing • Functional Testing • Controls • User Interface • Whole Application • The earlier we catch a “bug” or potential problem the less it costs! • Image • Manpower

  11. IT Has a Problem

  12. Test Early and Often • Catching defects as early as possible is the least expensive way to ensure software quality. • Kent Beck and Cynthia Andres wrote • "Here is the dilemma in software development: defects are expensive, but eliminating defects is also expensive”. • “However, most defects end up costing more than it would have cost to prevent them."

  13. The Testing TrendsForwards • Test-Driven Development • Design the Test • Then Write the Code

  14. The Testing TrendsBackwards - Circular • Linking • Help-Desk • Test • Story Board • Task • Unit • Programmer

  15. The Ultimate Goal of Software Testing • To find the bugs before your users do! • UI Testing is END USER TESTING • OR TOTAL SYSTEM TESTING • OR INFRASTRUCTURE TESTING

  16. Manual to Coded UI

  17. Testers Multiple Roles • Guarantee SOFTWARE QUALITY • Regression Test each Version or build • Test all Environments • Provide Developers with all the information required: • To REPRODUCE THE “BUG” • Trace the steps to get the BUG • Screen shots, IntelliTrace, Logs and Stack Traces • NO-REPRO must be ELIMINATED

  18. Tiers of Software Testing • Clear Separation of Functions • Clear Definition of Communication and Collaboration • TEAM of Software Quality

  19. 2)Walkthrough steps from beginning-to-end

  20. 2)Walkthrough steps from beginning-to-end • Lesson 1 Manual Testing • Using Microsoft Test Manger to create and manage Test Plans • Running Test Cases and Publishing Results • Conducting Exploratory Testing • Fast Forward for Manual Testing • Lesson 2 Coded User Interface Testing • Automated Functional Tests – Using CUIT • Create a CUIT from Scratch • Create a CUIT from action recording • Making CUIT more Robust and Flexible

  21. A manual testing process

  22. Building an AppFor Manual Testing • Demo of Simple Calculator

  23. Automating the Calculator • Demo

  24. Adding Data • Demo

  25. Introducing an Error • Demo

  26. Lab 1 • The Calculator

  27. 3 Creating Manual Tests

  28. Visual Studio 2012Supported Test Types

  29. Microsoft Test Manager • Provides a single environment to author and manage Tests

  30. Quick Start Guide for Manual Testing using Microsoft Test Manager • http://msdn.microsoft.com/en-us/library/dd380763.aspx

  31. Easily reproducing issues through manual testing • Introducing Managed Exploratory Testing • The 5 Minute “elevator” Video • http://channel9.msdn.com/Series/Visual-Studio-2012-Premium-and-Ultimate-Overview/Visual-Studio-Ultimate-2012-Easily-reproducing-issues-through-manual-testing

  32. 3) Creating a coded UI test Using Coded UI Test Builder

  33. 3) Creating a coded UI test Using Coded UI Test Builder • Test Types • Microsoft Test Manager • Exploratory Testing • Easily reproducing issues through manual testing

  34. Authoring a TEST case • Demo • Lab

  35. Microsoft Test Manager • The first time you run MTM it will prompt • Add Team Foundation Manager • “If you don’t know the Name contact your administrator” • It might require “ServerName:Port Number”

  36. TFS and MTM

  37. Connecting Microsoft Test Manager to TFS • MTM is always connected to TFS

  38. Test Plan Properties Figure 21-5. Test plan properties

  39. Test Suites • Static suite: The content of this suite is manually added test cases. • Query-based suite: A query-based suite lists all test cases matching a given work item filter. • Requirements-based suite: This suite shows the test cases associated with a selected TFS requirement.

  40. Static suite: The content of this suite is manually added test cases. • Query-based suite: A query-based suite lists all test cases matching a given work item filter. • Requirements-based suite: This suite shows the test cases associated with a selected TFS requirement.

  41. Configuring Test Settings • Establish Environments • Diagnostic Connectors • Best Practice • Work with Development Teams • The Developers need to have the same tools to view the test data you collected for them • Microsoft released a “Test Attachment Cleaner” available at • “Aka.ms./TFPowerTools”

  42. Using Builds • Scout • Installing Software and running some initial tests • After the SCOUT is successful it can become a “template for other Testers” • There is an available builds DROPDOWN • Click “ASSIGN TO PLAN” to add a new build to a plan

  43. Analyzing Impacted Tests • Quickly identify tests that need to be run based on changes to code • Can Run in the background • “Track” menu => Recommended Tests • Does not recognize “DATA” changes • Does not recognize other library changes • Does not recognize other Application changes • Best Practice - Periodicaly run all Tests

  44. Defining Multiple Test Configurations • Environments may differ: • IE 8,9,10 • Ipad Horizontal/Vertical • BYOD • HTML5 • ETC.

  45. Test Cases are organized in to Suites • Requirements-Based test suite • Query-Based test suite • Static Test Suite • Status of tests in TEST SUITE • In planning • In Progress • Completed

More Related