Improving Selenium IDE

Posted: July 7th, 2010 | Author: Dave | Filed under: Improvements | Tags: , | 1 Comment »

I’ve been working on a new formatter plugin for Selenium IDE, and along the way I discovered some quirks (not necessarily bugs) in the code. After a few discussions with some of the Selenium community, I decided to get stuck in and see if I couldn’t make some improvements. In the interest of sharing my experiences, here is what I did.

Format header/footer caching
For some reason (still not clear to me) the Selenium IDE formatter headers & footers were cached in two places, the TestCase itself, and also within the Format. I was finding that when switching between my new format and the default HTML, whichever I used first was persisting as the header/footer for the other. This could be fixed by using the Formatter cached header/footer but as I couldn’t see any advantage of caching this content, it seems like an unnecessary and overcomplicated solution. So I removed the caching entirely.

Updating variables in format source
The other main issue I had was when updating the base URL in Selenium IDE the format source is not updated. By removing the caching I’d partially solved this, but it still required the user to switch to another format and back again. Also, changes to variables from the format options pane also need to update the format source. I was able to find the appropriate place to initiate a refresh of the format source.

Setting the initial base URL
Finally, I had an issue where the initial base URL in the format source was not correct. When I tracked down the right place to put this minor fix I found the line I needed was already there but commented out! After a quick check, it appears that the change may have been a mistake, so I brought it back in and ran a few successful tests.

Obviously these changes are fairly significant, so the next release of Selenium IDE (1.0.8) will need to be well tested. At this time there isn’t a build available with these changes, but if you are confident with running a potentially unstable version you can check out from SVN and build Selenium IDE yourself.

Please get in touch if you have any feedback. You can raise any issues you find in the official issue tracker. Please label them as ‘ide’.

Stay tuned for more details on my new formatter – I have a few more issues to work through before I’m ready to release it, and some of these may even involve further improvements to Selenium IDE.


From IDE to Selenium 2

Posted: April 22nd, 2010 | Author: Dave | Filed under: Events | Tags: , , , , | 5 Comments »

Here are the slides from my ‘From IDE to Selenium 2′ talk that I gave at the second London Selenium Users meetup. Slides from the other talks to follow.

View more presentations from davehunt82.

Full project containing Selenium IDE test script, Selenium 2 Java TestNG tests (including dependancies), and slides available in this public Subversion repository.


Selenium IDE – My plugin baby

Posted: February 22nd, 2010 | Author: Dave | Filed under: Plugins | Tags: , , | 2 Comments »

With last month’s release of Selenium IDE 1.0.4 came initial support for plugins, and this month’s release of 1.0.5 continues to build on the new plugin API as well as fixing a few bugs.

This is quite possibly the most exciting development in Selenium IDE in a long time, and the best thing is that it enables users to come up with their own improvements – in much the same way as Greasemonkey or Firefox addons themselves. The possibilities are endless.

Adam Goucher continues to post guidance on creating plugins on his blog as the API evolves. I have followed these myself to create two plugins:

  • Flow control – This is actually just an old Selenium user extension that I’ve repackaged into a plugin. Two main advantages of doing this are: an easy install/disable/uninstall process, and no messing around with JavaScript files! [install] [public repository]
  • WebDriver Backed Selenium Formatters – This is a formatter plugin that provides the Selenium emulation from WebDriver, giving quick access to WebDriver’s advantages without changing from the existing Selenium API. [install] [public repository]

These plugins are available to download from SeleniumExamples, and you can view the source/report issues/provide feedback via the GitHub repositories.

Let SeleniumExamples know if you’re developing your own plugin, or have any good ideas. I’ll be happy to review, host, or link to your plugins – most of all we want to encourage plugin development.

Update:
Plugins now made available via addons.mozilla.org: