fix last test for deleting context

This commit is contained in:
Reinier Balt 2010-10-23 18:12:46 +02:00
parent e52a8609c7
commit 4e9777dc88
2 changed files with 7 additions and 2 deletions

View file

@ -27,6 +27,8 @@ Feature: Manage the list of contexts
Given I have a context called "@computer"
And I have a hidden context called "@ipad"
When I go to the contexts page
And I should see that the context container for active contexts is present
And I should see that the context container for hidden contexts is present
When I delete the context "@computer"
Then I should see that a context named "@computer" is not present
And I should see that the context container for active contexts is not present

View file

@ -47,8 +47,11 @@ Then /^I should see that a context named "([^"]*)" is not present$/ do |context_
end
Then /^I should see that the context container for (.*) contexts is not present$/ do |state|
present = selenium.is_element_present("list-contexts-#{state}'")
present.should_not be_true
selenium.is_visible("list-#{state}-contexts-container").should_not be_true
end
Then /^I should see that the context container for (.*) contexts is present$/ do |state|
selenium.is_visible("list-#{state}-contexts-container").should be_true
end
Then /^I should see the context "([^"]*)" under "([^"]*)"$/ do |context_name, state|