commit
5598cd803a
9 changed files with 18 additions and 46 deletions
|
|
@ -4,9 +4,9 @@ Feature: The activity stream
|
|||
Given a user with username "bob"
|
||||
When I sign in as "bob@bob.bob"
|
||||
|
||||
And I post "A- I like turtles"
|
||||
And I post "B- barack obama is your new bicycle"
|
||||
And I post "C- barack obama is a square"
|
||||
And I click the publisher and post "A- I like turtles"
|
||||
And I click the publisher and post "B- barack obama is your new bicycle"
|
||||
And I click the publisher and post "C- barack obama is a square"
|
||||
|
||||
When I go to the activity stream page
|
||||
Then "C- barack obama is a square" should be post 1
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ Feature: following and being followed
|
|||
Then I should have 1 contact in "Besties"
|
||||
|
||||
When I am on the home page
|
||||
And I post "I am following you back"
|
||||
And I click the publisher and post "I am following you back"
|
||||
Then I sign out
|
||||
|
||||
When I sign in as "bob@bob.bob"
|
||||
|
|
@ -88,7 +88,7 @@ Feature: following and being followed
|
|||
And I am on "alice@alice.alice"'s page
|
||||
|
||||
Then I should see "Besties"
|
||||
Then I should see a "#mention_button" within "#profile"
|
||||
Then I should see a "#mention_button" within "#profile"
|
||||
Then I should not see a "#message_button" within "#profile"
|
||||
|
||||
Scenario: interacting with the profile page of someone who follows you but who you do not follow
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ Feature: posting
|
|||
|
||||
Scenario: can post a message from the tag page
|
||||
Then I should see "#boss" within "#publisher"
|
||||
And I post "#boss from the tag page"
|
||||
And I click the publisher and post "#boss from the tag page"
|
||||
And I search for "#boss"
|
||||
Then I should see "#boss from the tag page"
|
||||
|
||||
|
|
@ -31,7 +31,7 @@ Feature: posting
|
|||
Scenario: see a tag that I am following and I post over there
|
||||
When I go to the home page
|
||||
And I follow "#boss"
|
||||
And I post "#boss from the #boss tag page"
|
||||
And I click the publisher and post "#boss from the #boss tag page"
|
||||
Then I should see "#boss from the #boss tag page" within "body"
|
||||
|
||||
Scenario: can stop following a tag from the tag page
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@ Scenario: Toggling nsfw state
|
|||
And a user with email "laura@officeworkers.com"
|
||||
And a user with email "laura@officeworkers.com" is connected with "tommy@pr0nking.com"
|
||||
When I sign in as "tommy@pr0nking.com"
|
||||
And I post "I love 0bj3ction4bl3 c0nt3nt!"
|
||||
And I post "Sexy Senators Gone Wild!"
|
||||
And I click the publisher and post "I love 0bj3ction4bl3 c0nt3nt!"
|
||||
And I click the publisher and post "Sexy Senators Gone Wild!"
|
||||
Then I should have 2 nsfw posts
|
||||
|
||||
#toggling global nsfw state
|
||||
|
|
@ -33,16 +33,11 @@ Scenario: Toggling nsfw state
|
|||
When I toggle nsfw posts
|
||||
Then I should see "I love 0bj3ction4bl3 c0nt3nt!" and "Sexy Senators Gone Wild!"
|
||||
|
||||
#cookies
|
||||
#When I refresh the page
|
||||
#Then I should see "I love 0bj3ction4bl3 c0nt3nt!"
|
||||
#And I should see "Sexy Senators Gone Wild!"
|
||||
|
||||
#hiding
|
||||
When I toggle nsfw posts
|
||||
Then I should not see "I love 0bj3ction4bl3 c0nt3nt!" and "Sexy Senators Gone Wild!"
|
||||
|
||||
Scenario: Resharing an nsfw post
|
||||
Scenario: Resharing a nsfw post
|
||||
Given a nsfw user with email "tommy@pr0nking.com"
|
||||
And a user with email "laura@officeworkers.com"
|
||||
And a user with email "laura@officeworkers.com" is connected with "tommy@pr0nking.com"
|
||||
|
|
|
|||
|
|
@ -51,24 +51,16 @@ Feature: new user registration
|
|||
And I fill in the following:
|
||||
| user_username | $%&(/&%$&/=)(/ |
|
||||
And I press "Continue"
|
||||
|
||||
Then following fields should have validation errors:
|
||||
| user_username |
|
||||
| user_email |
|
||||
| user_password |
|
||||
Then I should see a flash message containing "Email can't be blank - Password can't be blank - Username is invalid."
|
||||
|
||||
When I fill in the following:
|
||||
| user_username | valid_user |
|
||||
| user_email | this is not a valid email $%&/()( |
|
||||
And I press "Continue"
|
||||
|
||||
Then following fields should have validation errors:
|
||||
| user_email |
|
||||
| user_password |
|
||||
Then I should see a flash message containing "Email is invalid - Password can't be blank"
|
||||
|
||||
When I fill in the following:
|
||||
| user_email | valid@email.com |
|
||||
| user_password | 1 |
|
||||
And I press "Continue"
|
||||
Then following field should have validation error:
|
||||
| user_password |
|
||||
Then I should see a flash message containing "Password doesn't match confirmation - Password is too short (minimum is 6 characters)"
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ Feature: Issue #3382 The comments under postings are missing when using the #tag
|
|||
Background:
|
||||
Given a user named "Bob Jones" with email "bob@bob.bob"
|
||||
And I sign in as "bob@bob.bob"
|
||||
When I post "This is a post with a #tag"
|
||||
When I post a status with the text "This is a post with a #tag"
|
||||
And I am on the homepage
|
||||
|
||||
Scenario:
|
||||
|
|
|
|||
|
|
@ -60,17 +60,6 @@ And /^I submit the form$/ do
|
|||
find("input[type='submit']").click
|
||||
end
|
||||
|
||||
Then /^the "([^"]*)" field should have a validation error$/ do |field|
|
||||
find_field(field).has_xpath?(".//ancestor::div[contains(@class, 'control-group')]/div[contains(@class, 'field_with_errors')]")
|
||||
end
|
||||
|
||||
|
||||
Then /^following field[s]? should have validation error[s]?:$/ do |fields|
|
||||
fields.raw.each do |field|
|
||||
step %{the "#{field[0]}" field should have a validation error}
|
||||
end
|
||||
end
|
||||
|
||||
And /^I expand the publisher$/ do
|
||||
click_publisher
|
||||
end
|
||||
|
|
|
|||
|
|
@ -51,10 +51,6 @@ Then /^I should see "([^"]*)" as the first post in my stream$/ do |text|
|
|||
first_post_text.should include(text)
|
||||
end
|
||||
|
||||
When /^I post "([^"]*)"$/ do |text|
|
||||
click_and_post(text)
|
||||
end
|
||||
|
||||
When /^I click the publisher and post "([^"]*)"$/ do |text|
|
||||
click_and_post(text)
|
||||
end
|
||||
|
|
|
|||
|
|
@ -26,13 +26,13 @@ module PublishingCukeHelpers
|
|||
|
||||
def first_post_collapsed?
|
||||
find(".stream_element .collapsible", match: :first).should have_css(".expander")
|
||||
find(".stream_element .collapsible", match: :first).has_selector?(".collapsed")
|
||||
page.should have_css(".stream_element .collapsible.collapsed", match: :first)
|
||||
end
|
||||
|
||||
def first_post_expanded?
|
||||
has_no_css?(".stream_element .expander", match: :first).should be_true
|
||||
find(".stream_element .collapsible", match: :first).has_no_selector?(".collapsed")
|
||||
find(".stream_element .collapsible", match: :first).has_selector?(".opened")
|
||||
page.should have_no_css(".stream_element .expander", match: :first)
|
||||
page.should have_no_css(".stream_element .collapsible.collapsed", match: :first)
|
||||
page.should have_css(".stream_element .collapsible.opened", match: :first)
|
||||
end
|
||||
|
||||
def first_post_text
|
||||
|
|
|
|||
Loading…
Reference in a new issue