November 11, 2008

Watir Released with Improved Support for Firefox

Last week we released Watir 1.6.2. This is a big release with a lot of new features and fixes, but the focus has been integrating the Watir and FireWatir code bases and improving our support for Firefox. Earlier this year we put both projects under the same umbrella. This release significantly improves compatibility. Many of our users are finding that they can now run all or nearly all of their tests on both IE and Firefox.

We've also provided other features and fixes that will be of interest to users who don't care about Firefox (if such people exist). It is backwards compatabible, so we expect all Watir users will be upgrading to this release. Install or upgrade to this release.

And the end of this note, we mention a few issues that people have encountered when upgrading to this version.

Firefox Support

We've fixed many of the reported compatibility issues. FireWatir now supports nearly all off of the elements supported by Watir. Also both implementations now support being able to specify page elements using multiple attributes (e.g. browser.button(:name => 'Purchase", :index => 2).click). Lots of other issues, detailed in the release notes, have also been fixed.

Both Watir and FireWatir users can simply upgrade and continue to run their existing tests. But they can also make use of our new generic browser interface.

require 'watir'
browser = Watir::Browser.new
Once you have changed your tests to use this instead of Watir::IE.new, then you can configure which browser will be used at runtime.

Modal Dialog Support

We have updated Watir's modal dialog support to work with Ruby 1.8.6. Previously, users who needed to work with the showModalDialog had to use Ruby 1.8.2, but this restriction is no longer in place. We now recommend that all Watir users use the latest version of Ruby 1.8.6.

Speed Improvements on IE

We made some speed improvements in early version of Watir 1.5 that stopped working with version 1.5.4 - 1.5.6. These speed improvements are now working again. Users who had not upgraded to 1.5.6 because of performance concerns should upgrade to this release of Watir.

We've also added unit tests that will alert us if we happen to break this functionality in the future. Sorry about that.

Multiple Attribute Support for All Page Elements

I mentioned this above, but it bears repeating. Previously, Watir allowed you to access some page elements using multiple attributes, but you could only use a single attribute to access input elements such as buttons or text fields or select lists. Now you can use multiple attributes to access any of these elements. There is no limit to the number of attributes you can use. In other words, multiple attribute support has been improved for both IE and Firefox

Don't use "include Watir" at Toplevel

For some time, we've been telling people to avoid using "include Watir" in their scripts because it had the potential to cause unforeseeable problems. With this release, it causes conflicts with one of the other libraries that Watir uses. If you have been using "include Watir" in your scripts please read our detailed advice on this topic.

Builder Error is Benign

When installing Watir 1.6.2, some users will see this error.

ERROR:  While generating documentation for builder-2.1.2
... MESSAGE:   Unhandled special: Special: type=17, text="<!-- HI -->"
... RDOC args: --ri --op e:/ruby/lib/ruby/gems/1.8/doc/builder-2.1.2/ri --title
Builder -- Easy XML Building --main README --line-numbers --quiet lib CHANGES Ra
kefile README doc/releases/builder-1.2.4.rdoc doc/releases/builder-2.0.0.rdoc do
c/releases/builder-2.1.1.rdoc
It is harmless and can be ignored. All it means is that the documentation for the Builder gem could not be generated. Everything else will work.

Unit Tests Won't Run from Gems

You can no longer run Watir's unit tests from within a gem. This is because we have started integrating our Watir/FireWatir test suites and they have cross dependencies. They still run fine from source. You and run them yourself. We also run them everyday and publicly post results.

Posted by bret at 02:56 PM | Comments (1)