using selenium-rc can i load a page, click a bookmarklet, and fill up the in-page loaded form?

StackOverflow https://stackoverflow.com/questions/1029533

  •  06-07-2019
  •  | 
  •  

Question

Is there anyway by which I can automate the following steps in Selenium-rc

  1. open a page
  2. click on bookmarklet in browser toolbar
  3. fill up data in the form loaded into the page by said bookmarklet.

If the bookmarklet is not accessible as it is part of the browser/bookmark toolbar, is there a way in which I can inject the javascript into the page and have it execute?

Was it helpful?

Solution

You are 99% there! You're right, you can't actually click the bookmarklet, but you can inject the same JavaScript in to the page. Simply use the getEval() command to evaluate the JavaScript.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top