re-write tests for the (reverse) has_many features (#164)

This commit is contained in:
did 2011-08-14 14:07:15 -07:00
parent 8d30ba5152
commit 3ad8101ed6
2 changed files with 10 additions and 19 deletions

View File

@ -32,7 +32,7 @@ Scenario: I view a client without any projects
And I follow "Alpha, Inc" And I follow "Alpha, Inc"
And I wait until the has many selector is visible And I wait until the has many selector is visible
Then I should see "Empty" within the list of items Then I should see "Empty" within the list of items
@javascript @javascript
Scenario: I add a project to a client Scenario: I add a project to a client
When I go to the "Clients" model list page When I go to the "Clients" model list page
@ -43,9 +43,11 @@ Scenario: I add a project to a client
When I press "Save" When I press "Save"
And I wait until the has many selector is visible And I wait until the has many selector is visible
Then I should see "Fun project" within the list of added items Then I should see "Fun project" within the list of added items
And I should not see "Empty" within the list of items And "Fun project" should not be an option for "label"
When I go to the "Clients" model list page #
And I follow "Beta, Inc" # And I should not see "Empty" within the list of items
And I wait until the has many selector is visible # When I go to the "Clients" model list page
Then I should see "Fun project" within the list of added items # And I follow "Beta, Inc"
And I should not see "Empty" within the list of items # And I wait until the has many selector is visible
# Then I should see "Fun project" within the list of added items
# And I should not see "Empty" within the list of items

View File

@ -44,12 +44,6 @@ Scenario: I attach already created items for an existing parent and save it
When I press "Save" When I press "Save"
And I wait until the has many selector is visible And I wait until the has many selector is visible
Then "My sexy project" should not be an option for "label" Then "My sexy project" should not be an option for "label"
When I go to the "Clients" model list page
And I follow "Apple Inc"
And I wait until the has many selector is visible
Then "My sexy project" should not be an option for "label"
And I should not see "Empty" within the list of items
@javascript @javascript
Scenario: I create a new item and attach it Scenario: I create a new item and attach it
@ -64,9 +58,4 @@ Scenario: I create a new item and attach it
Then I should see "Content was successfully created." Then I should see "Content was successfully created."
When I wait until the has many selector is visible When I wait until the has many selector is visible
Then I should see "iPad" Then I should see "iPad"
And "iPad" should not be an option for "label" And "iPad" should not be an option for "label"
When I go to the "Clients" model list page
And I follow "Apple Inc"
And I wait until the has many selector is visible
Then "iPad" should not be an option for "label"
And I should not see "Empty" within the list of items