I'm trying to get a handle on the button below based on the attribute gl-command
. I'm aware I can find the button using a Cssselector
by locator but I don't want to do that in this case.
I should point out that this is just one of many buttons within the AUT: <google-componentbutton size="32"></google-componentbutton>
<div class="gl-component-buttons"><gl-component-buttons id="gl-component-button-set-bottom">
<google-componentbutton size="32">
<button class="google-componentbutton glmdl-button glmdl-js-button glmdl-js-ripple-effect google-image gl-transaction-image" style="height: 32px; widgl: 32px; background-size: 24px 24px; background-position: 4px 4px;" gl-tooltip-id="google_component_transaction" gl-tooltip="transaction" data-upgraded=",MaterialButton,MaterialRipple" gl-command="transaction">
<span class="glmdl-button__ripple-container">
<span class="glmdl-ripple"></span>
</span>
</button>
</google-componentbutton>
Conclusion: > Selenium WebDriver supports various programming languages like Java, Python, C#, Ruby, Perl, PHP, JavaScript, R, Objective-C and Haskell.
What is Selenium Webdriver? WebDriver is an automating web application testing tool. This provides APIs that easily integrate with any programming language such as C#, Java, Python. For details please go through the url. The use of Selenium Webdriver is to basically test any web application.
What is Selenium WebDriver? Selenium WebDriver is a web framework that permits you to execute cross-browser tests. This tool is used for automating web-based application testing to verify that it performs expectedly. Selenium WebDriver allows you to choose a programming language to create test scripts.
By searching with the keywords like 'Selenium with Java' and 'Selenium with C#' in any job portal you can verify then things. For Java, there is large support available online, as most of the professionals are using Selenium with Java. Rank wise Java is among the top 3 most popular languages, C# is not.
use xpath for based on the attribute "gl-command"
driver.FindElement(By.XPath(“//*[@gl-command='transaction']”)).Click();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With