I have tired everything Actions class, java script, move to element, click and hold etc. I have tried a lot of things. Seems like it don't work with vue.js or HTML 5 as our application is built using html5 and vue.js. What is does is it click and holds the element but don't drop it.
I'm working on a some automation work, as per my requirement I need to click on Chrome Physical buttons like left nav, right nav, bookmarks, menu etc. I can do with shortcuts but my requirement is to click on browser buttons. Any ideas would be helpful. Thanks in advance.
As per your question you want to click on Chrome Physical buttons like left navigation, right navigation, bookmarks, menu etc.
But if you look into the documentation in Selenium Home Page it clearly mentions that :
The entire suite of tools provided by Selenium results in a rich set of testing functions specifically geared to the needs of testing of web applications. These operations allow many options for locating UI elements and comparing expected test results against actual application behavior.
So factually Selenium by design interacts with the HTML DOM and the WebElements located in the DOM Tree
Now the desired controls e.g. left navigation, right navigation, bookmarks, menu are out of the DOM. Hence you cannot mock the click on those controls.
However all the Selenium Language Binding Art provides a handfull of methods to achieve the same result. Here are a few from the Selenium Python Binding Art :
Maximize : To maximize the browser window.
driver.maximize_window()
Minimize : To minimize the browser window.
driver.minimize_window()
Close : To close the browser window.
driver.close()
Quit : To close the browser window gracefully.
driver.quit()
Refresh : To refresh the url.
driver.refresh()
Forward : To move forward.
driver.forward()
Back : To move backwards.
driver.back()
And of-coarse Get : To invoke an url.
driver.get('http://google.com/')
There are functions for this that is built-in:
driver.forward()
driver.back()
https://selenium-python.readthedocs.io/navigating.html#navigation-history-and-location
It doesn't appear that selenium can interact with the Bookmark, but let me check some more.
This can't be done with selenium webdriver and I think also not with the standalone selenium server. Selenium only allows to interact with the DOM.
The only way to achieve what you want to do is to use an automation tool that actually runs directly in the OS that you use. Java can be used to write such a program.
I would however recommend to not go this route. Instead try to convince whoever is responsible for your requirements to re-think and allow to use other means of achieving back and forward actions.
I have test one web based application using selenium, which comes with some animation. That animation's conversation(cc text) will comes in a web element area.
Each on screen text time interval is different. Then how to verify this text using selenium web-driver.
I am using Selenium web driver with Java in test automation framework of WebApplication which is portlet based using Java.My workflow is...
On Wizard Page-1: a container available having 2-3 input/edit boxes, some dropdown list(using Select class) and few buttons. That is like Wizard. After entering all required data on wizard of page-1. then click to Next button to navigate to Wizard Page-2.
On Wizard Page-2: First option is dropdown list where we use Select class i.e. selectByValue/selectByIndex etc.But during of after this action,application showed like scrolling up. But when we observed, actually it hides the first line of all webelements on Page-2.
I am sharing the screenshots for problem. Shared two images are, one is before action or real screen and second one is which hides few web element after the action.
image can be accessed: https://drive.google.com/open?id=0By2IDRpIvYf7SnphOVB4R1N3aTg
I have a situation where I need to push text to 3 text boxes of a small one-form Swing application and then press a button (in other words, automation). The application is not written by me and is available only as a jar file.
The situation is similar to that of test frameworks that do UI test automation. (If it were a Windows / .NET / SWT application, something like Project White framework would be useful. )
Is such a thing is possible? Thanks in advance.
You can fix the swing application on the desktop, and get the absolute positions of text boxes and the button. Then, use the quick macro to send the right events of keyboard and mouse to the swing application.