Skip to main content

Posts

Showing posts from June, 2020

Locate disappearing elements

You don't have access to the source code and want to inspect elements like HTML5 validation error messages, Wait icon, dynamic search list, or for that matter any disappearing element in your browser that disappears when your mouse moves away?  There are many ways to do that but using below we should be able to capture most of those kinds of disappearing elements/scenarios: Open Chrome Go to that page where you would like to inspect the disappearing element Open dev tools (F12) Select the "Sources" tab While the element you want is displayed, press F8. This should halt the script execution by freezing the DOM (Paused in debugger mode) As the DOM is in the frozen state, now we should be able to hover/select that element to inspect that. #smallAndOldTip #TipsAndTricks #testAutomation #devTools

Where should we keep sensitive information in automation projects?

Of course, nothing can beat encryption/decryption to safeguard our sensitive data but here is one more approach to store your project data and retrieve. Environment Variables are key/value pairs like Properties. We can use this to allow config (sensitive) information to be passed into applications. We can use it in any automation project, not necessarily for Selenium only. Like every approach this too has it’s own pros and cons but for sure, it’s better than keeping your sensitive date in code directly or in a property file. Good read by Alex — https://medium.com/@alexsiminiuc/in-selenium-projects-keep-sensitive-information-in-environment-variables-3c9eb6521080