fix failing specs due to invalid css

This commit is contained in:
Thomas Walpole 2013-02-18 13:08:34 -08:00
parent 4a5876d95e
commit fb6c0ce9e5
1 changed files with 3 additions and 3 deletions

View File

@ -5,7 +5,7 @@ Capybara::SpecHelper.spec '#within' do
context "with CSS selector" do
it "should click links in the given scope" do
@session.within(:css, "#for_bar li[contains('With Simple HTML')]") do
@session.within(:css, "#for_bar li", text: 'With Simple HTML') do
@session.click_link('Go')
end
@session.should have_content('Bar')
@ -46,7 +46,7 @@ Capybara::SpecHelper.spec '#within' do
context "with Node rather than selector" do
it "should click links in the given scope" do
node_of_interest = @session.find(:css, "#for_bar li[contains('With Simple HTML')]")
node_of_interest = @session.find(:css, "#for_bar li", text: 'With Simple HTML')
@session.within(node_of_interest) do
@session.click_link('Go')
@ -58,7 +58,7 @@ Capybara::SpecHelper.spec '#within' do
context "with the default selector set to CSS" do
before { Capybara.default_selector = :css }
it "should use CSS" do
@session.within("#for_bar li[contains('With Simple HTML')]") do
@session.within("#for_bar li", text: 'With Simple HTML') do
@session.click_link('Go')
end
@session.should have_content('Bar')