Adding example for clicking a link with an amperstand
This commit is contained in:
parent
dc52f07a9f
commit
5a9c048dfb
|
@ -5,6 +5,14 @@ describe "click_link" do
|
|||
@session = Webrat::TestSession.new
|
||||
end
|
||||
|
||||
it "should click links with ampertands" do
|
||||
@session.response_body = <<-EOS
|
||||
<a href="/page">Save & go back</a>
|
||||
EOS
|
||||
@session.should_receive(:get).with("/page", {})
|
||||
@session.click_link "Save & go back"
|
||||
end
|
||||
|
||||
it "should use get by default" do
|
||||
@session.response_body = <<-EOS
|
||||
<a href="/page">Link text</a>
|
||||
|
|
Loading…
Reference in New Issue