BT12 Test Automation 11/17/2016 3:00:00 PM Build Fail-Proof Tests in Any Browser with Selenium Presented by: Kevin Berg Sauce Labs Brought to you by: 350 Corporate Way, Suite 400, Orange Park, FL 32073 888--‐268--‐8770 ·∙ 904--‐278--‐0524 - [email protected]- http://www.stareast.techwell.com/
16
Embed
Build Fail-Proof Tests in Any Browser with Selenium
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
BT12 Test Automation 11/17/2016 3:00:00 PM
Build Fail-Proof Tests in Any Browser with Selenium
Presented by:
Kevin Berg
Sauce Labs
Brought to you by:
350 Corporate Way, Suite 400, Orange Park, FL 32073
Kevin Berg is a customer automation specialist at Sauce Labs where he works with prospective, new, and existing customers to adapt their tests and frameworks to enhance their parallel and cross browser testing capabilities. Kevin has written test framework examples that exhibit both parallel execution and cross browser testing capability for desktop and mobile platforms. As a proponent of open source materials, these examples are publicly available on GitHub (@KevinMarkVI). A classical musician turned software engineer, Kevin enjoys watching sports, playing video games, and spending time outdoors with his wife and dog.
11/1/2016
1
F a i l P r o o f Te s t s i n A n y B r o w s e r F a i l P r o o f Te s t s i n A n y B r o w s e r w i t h S e l e n i u mw i t h S e l e n i u mw i t h S e l e n i u mw i t h S e l e n i u mK E V I N B E R G , C U S T O M E R A U T O M AT I O N
S P E C I A L I S T
Kevin Berg
A little about me:
D r . K e v i n B e r g , D M A
• Help customers transition from running test manually or on local Selenium grids, to parallel cross-browser testing in the cloud
• Write custom testing frameworks, features, and Selenium scripts
• Selenium/Appium workshops and training
• CI/CD architecture and integrationCI/CD architecture and integration
• Built in mechanisms that will allow for variation in website page• Built in mechanisms that will allow for variation in website page loading times and/or dynamically loading elements
Tells the WebDriver to poll the browser DOM for a certain amount• Tells the WebDriver to poll the browser DOM for a certain amount of time when trying to find an element or elements if they are not immediately available.
• Code you define to wait for a certain condition to occur beforeCode you define to wait for a certain condition to occur before proceeding further in the test.
• E.g. Poll the DOM until the element I’m looking for is visible
• Used with individual elements as opposed to a blanket timeout on the WebDriver instance
They sound similar, and a Sleep is also a type of Explicit Wait?
Ne er se Sleeps• Never use Sleeps
• Don’t use Implicit Waits
• Can cause problems when the element you are trying to interact with is not ready• E.g. Can be found in the browser DOM before it is visible• Hidden/Disabled elements• Use Explicit Waits that Wait for a Condition (Not Time)
• Element to be Enabled, Visible, Clickable, Selected