When (/^the click me button on the simple object test page is clicked$/) do step %{on the object test page} @page.clickmeID end When (/^the click me button on the object test page is clicked by "([^"]*)"$/) do |locator| @page = SimpleObjectPage.new(@browser, true) @page.clickmeID if locator == "id" @page.clickmeName if locator == "name" @page.clickmeClass if locator == "class" @page.clickmeXPath if locator == "xpath" @page.clickmeIndex if locator == "index" @page.clickmeValue if locator == "value" @page.clickmeText if locator == "text" @page.clickmeCSS if locator == "css" end Then (/^the click me button should exist$/) do @page.clickmeID_exists?.should == true @page.clickmeID?.should == true end Then (/^the can't click me button should exist$/) do @page.cantClickMeID_exists?.should == true end Then (/^the click me button should be visible$/) do @page.clickmeID_visible?.should == true @page.clickmeID_?.should == true end Then (/^the can't click me button should be visible$/) do @page.cantClickMeID_visible?.should == true end Then (/^the click me button should be enabled$/) do @page.clickmeID_enabled?.should == true @page.clickmeID!.should == true end Then (/^the can't click me button should not be enabled$/) do @page.cantClickMeID_enabled?.should == false end Then (/^the click me button should be a button object$/) do @object = @page.clickmeID_button @object.should be_instance_of Symbiont::WebObjects::Button end Then (/^the can't click me button should be a button object$/) do @object = @page.cantClickMeID_button @object.should be_instance_of Symbiont::WebObjects::Button end Then (/^the text of the click me button should be "([^"]*)"$/) do |text| @page.clickmeID_text.should == text end Then (/^the text of the can't click me button should be "([^"]*)"$/) do |text| @page.cantClickMeID_text.should == text end Then (/^the fake button should not exist$/) do @page.fake_button_exists?.should == false end Then (/^the fake button should be a button object$/) do @object = @page.fake_button_object @object.should be_instance_of Symbiont::WebObjects::Button end