Skip to content

Commit 2cebc66

Browse files
committed
User-Agent refactoring
1 parent e54a48e commit 2cebc66

8 files changed

Lines changed: 4 additions & 20 deletions

File tree

features/answers.feature

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@ Feature: CRUD actions for answers
22

33
As a user of the site, I can perform standard CRUD actions on answers
44

5-
Background:
6-
Given "Mac" user agent
7-
85
Scenario: Create an answer
96
And a question exists
107
And I answer that question

features/blog.feature

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
Feature: Hackety Blog
22

33
As an admin, I can post to the hackety blog.
4-
5-
Background:
6-
Given "Mac" user agent
7-
4+
85
Scenario: Read the blog
96
Given a blog post exists
107
When I visit the blog

features/moderator.feature

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ Feature: Moderate questions
33
As a moderator, I should be able to delete questions from the site.
44

55
Background:
6-
Given "Mac" user agent
7-
And there is a question from someone else
6+
Given there is a question from someone else
87

98
Scenario: Delete a question
109
Given I am a moderator

features/programs.feature

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@ Feature: Access Programs
22

33
As a user of the site, I want to access users' programs
44

5-
Background:
6-
Given "Mac" user agent
7-
85
Scenario: View a featured program
96
Given there is a featured program
107
Then I should be able to view a highlighted program

features/questions.feature

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@ Feature: CRUD actions for question
22

33
As a user of the site, I can perform standard CRUD actions on questions
44

5-
Background:
6-
Given "Mac" user agent
7-
85
Scenario: Create a question
96
When I create a new question
107
Then I should be told the question was created

features/signup.feature

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@ Feature: Sign up for an account
22

33
As a new Hackety user, I want to create a new account and log in with it
44

5-
Background:
6-
Given "Mac" user agent
7-
85
Scenario: Create an account via the signup form
96
When I register a new account
107
Then I should be logged in with my new account

features/support/env.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040

4141
Before do
4242
DatabaseCleaner[:mongo_mapper].clean
43+
page.driver.header('User-Agent', "Mac")
4344
end
4445

4546
# You may also want to configure DatabaseCleaner to use different strategies for certain features and scenarios.

features/users.feature

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ Feature: Manage account
33
As a user of this site, I can view and update my profile, see my followers
44

55
Background:
6-
Given "Mac" user agent
7-
And a logged in user
6+
Given a logged in user
87

98
Scenario: View my profile
109
When I go to look at my profile page

0 commit comments

Comments
 (0)