|
Red Squirrel Reflections
Dave Hoover explores the psychology of software development
|
|
Fri, 13 Oct 2006On the plane to San Jose last week I polished off another SafariWatir release. This will likely be the last release for a while. Due to the flooding that we experienced last week, I have become very focused on revenue-generating activities in the short-term. There's nothing like losing 1/3 of your living space and slow-to-respond insurance companies and a family of 5 to support to keep you focused on the bottom line! This release adds table and frame support, along with improving the click events. Here are some examples of what you can do with SafariWatir at this point...
require 'rubygems'
require 'safariwatir'
require 'test/unit/assertions'
include Test::Unit::Assertions
browser = Watir::Safari.new
browser.goto("http://www.geraldmweinberg.com/")
browser.frame("menu").link(:text, "Books").click
browser.frame("menu").link(:text, /psychology/i).click
assert_match /Silver Anniversary/, browser.frame("content").text
browser.goto("http://basecamphq.com/")
assert_match /What is Basecamp\?/, browser.table(:index, 1)[1][2].text
# First table
browser.close # First row
# Second cell
# Yes, Watir uses 1-based indexes.
|