summaryrefslogtreecommitdiff
path: root/features
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-02-20 11:59:59 -0200
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-02-20 12:39:27 -0200
commit3d52e139b13ad077286f2f9f46b7e98f43ad9564 (patch)
tree22c70561b0f64851d938e44661aafeed3a2c80b2 /features
parent408e010d65e7e2e2b64a694e12d44636d7d81dec (diff)
downloadgitlab-ce-3d52e139b13ad077286f2f9f46b7e98f43ad9564.tar.gz
Rename Tasks to Todos
Diffstat (limited to 'features')
-rw-r--r--features/dashboard/todos.feature (renamed from features/dashboard/tasks.feature)22
-rw-r--r--features/steps/dashboard/todos.rb (renamed from features/steps/dashboard/tasks.rb)64
-rw-r--r--features/steps/shared/paths.rb4
3 files changed, 45 insertions, 45 deletions
diff --git a/features/dashboard/tasks.feature b/features/dashboard/todos.feature
index 9d4f386f7dd..1e7b1b50d64 100644
--- a/features/dashboard/tasks.feature
+++ b/features/dashboard/todos.feature
@@ -1,5 +1,5 @@
@dashboard
-Feature: Dashboard Tasks
+Feature: Dashboard Todos
Background:
Given I sign in as a user
And I own project "Shop"
@@ -7,32 +7,32 @@ Feature: Dashboard Tasks
And "Mary Jane" is a developer of project "Shop"
And "Mary Jane" owns private project "Enterprise"
And I am a developer of project "Enterprise"
- And I have pending tasks
- And I visit dashboard task queue page
+ And I have todos
+ And I visit dashboard todos page
@javascript
- Scenario: I mark pending tasks as done
- Then I should see pending tasks assigned to me
- And I mark the pending task as done
+ Scenario: I mark todos as done
+ Then I should see todos assigned to me
+ And I mark the todo as done
And I click on the "Done" tab
- Then I should see all tasks marked as done
+ Then I should see all todos marked as done
@javascript
Scenario: I filter by project
Given I filter by "Enterprise"
- Then I should not see tasks
+ Then I should not see todos
@javascript
Scenario: I filter by author
Given I filter by "John Doe"
- Then I should not see tasks related to "Mary Jane" in the list
+ Then I should not see todos related to "Mary Jane" in the list
@javascript
Scenario: I filter by type
Given I filter by "Issue"
- Then I should not see tasks related to "Merge Requests" in the list
+ Then I should not see todos related to "Merge Requests" in the list
@javascript
Scenario: I filter by action
Given I filter by "Mentioned"
- Then I should not see tasks related to "Assignments" in the list
+ Then I should not see todos related to "Assignments" in the list
diff --git a/features/steps/dashboard/tasks.rb b/features/steps/dashboard/todos.rb
index 556aa41bad9..207d997f8a0 100644
--- a/features/steps/dashboard/tasks.rb
+++ b/features/steps/dashboard/todos.rb
@@ -1,4 +1,4 @@
-class Spinach::Features::DashboardTasks < Spinach::FeatureSteps
+class Spinach::Features::DashboardTodos < Spinach::FeatureSteps
include SharedAuthentication
include SharedPaths
include SharedProject
@@ -17,43 +17,43 @@ class Spinach::Features::DashboardTasks < Spinach::FeatureSteps
project.team << [john_doe, :developer]
end
- step 'I have pending tasks' do
- create(:task, user: current_user, project: project, author: mary_jane, target: issue, action: Task::MENTIONED)
- create(:task, user: current_user, project: project, author: john_doe, target: issue, action: Task::ASSIGNED)
+ step 'I have todos' do
+ create(:todo, user: current_user, project: project, author: mary_jane, target: issue, action: Todo::MENTIONED)
+ create(:todo, user: current_user, project: project, author: john_doe, target: issue, action: Todo::ASSIGNED)
note = create(:note, author: john_doe, noteable: issue, note: "#{current_user.to_reference} Wdyt?")
- create(:task, user: current_user, project: project, author: john_doe, target: issue, action: Task::MENTIONED, note: note)
- create(:task, user: current_user, project: project, author: john_doe, target: merge_request, action: Task::ASSIGNED)
+ create(:todo, user: current_user, project: project, author: john_doe, target: issue, action: Todo::MENTIONED, note: note)
+ create(:todo, user: current_user, project: project, author: john_doe, target: merge_request, action: Todo::ASSIGNED)
end
- step 'I should see pending tasks assigned to me' do
- expect(page).to have_content 'Tasks 4'
+ step 'I should see todos assigned to me' do
+ expect(page).to have_content 'Todos 4'
expect(page).to have_content 'Done 0'
expect(page).to have_link project.name_with_namespace
- should_see_task(1, "John Doe assigned merge request ##{merge_request.iid}", merge_request.title)
- should_see_task(2, "John Doe mentioned you on issue ##{issue.iid}", "#{current_user.to_reference} Wdyt?")
- should_see_task(3, "John Doe assigned issue ##{issue.iid}", issue.title)
- should_see_task(4, "Mary Jane mentioned you on issue ##{issue.iid}", issue.title)
+ should_see_todo(1, "John Doe assigned merge request ##{merge_request.iid}", merge_request.title)
+ should_see_todo(2, "John Doe mentioned you on issue ##{issue.iid}", "#{current_user.to_reference} Wdyt?")
+ should_see_todo(3, "John Doe assigned issue ##{issue.iid}", issue.title)
+ should_see_todo(4, "Mary Jane mentioned you on issue ##{issue.iid}", issue.title)
end
- step 'I mark the pending task as done' do
- page.within('.task:nth-child(1)') do
+ step 'I mark the todo as done' do
+ page.within('.todo:nth-child(1)') do
click_link 'Done'
end
- expect(page).to have_content 'Task was successfully marked as done.'
- expect(page).to have_content 'Tasks 3'
+ expect(page).to have_content 'Todo was successfully marked as done.'
+ expect(page).to have_content 'Todos 3'
expect(page).to have_content 'Done 1'
- should_not_see_task "John Doe assigned merge request ##{merge_request.iid}"
+ should_not_see_todo "John Doe assigned merge request ##{merge_request.iid}"
end
step 'I click on the "Done" tab' do
click_link 'Done 1'
end
- step 'I should see all tasks marked as done' do
+ step 'I should see all todos marked as done' do
expect(page).to have_link project.name_with_namespace
- should_see_task(1, "John Doe assigned merge request ##{merge_request.iid}", merge_request.title, false)
+ should_see_todo(1, "John Doe assigned merge request ##{merge_request.iid}", merge_request.title, false)
end
step 'I filter by "Enterprise"' do
@@ -69,28 +69,28 @@ class Spinach::Features::DashboardTasks < Spinach::FeatureSteps
end
step 'I filter by "Mentioned"' do
- select2("#{Task::MENTIONED}", from: '#action_id')
+ select2("#{Todo::MENTIONED}", from: '#action_id')
end
- step 'I should not see tasks' do
- expect(page).to have_content 'No tasks to show'
+ step 'I should not see todos' do
+ expect(page).to have_content 'No todos to show'
end
- step 'I should not see tasks related to "Mary Jane" in the list' do
- should_not_see_task "Mary Jane mentioned you on issue ##{issue.iid}"
+ step 'I should not see todos related to "Mary Jane" in the list' do
+ should_not_see_todo "Mary Jane mentioned you on issue ##{issue.iid}"
end
- step 'I should not see tasks related to "Merge Requests" in the list' do
- should_not_see_task "John Doe assigned merge request ##{merge_request.iid}"
+ step 'I should not see todos related to "Merge Requests" in the list' do
+ should_not_see_todo "John Doe assigned merge request ##{merge_request.iid}"
end
- step 'I should not see tasks related to "Assignments" in the list' do
- should_not_see_task "John Doe assigned merge request ##{merge_request.iid}"
- should_not_see_task "John Doe assigned issue ##{issue.iid}"
+ step 'I should not see todos related to "Assignments" in the list' do
+ should_not_see_todo "John Doe assigned merge request ##{merge_request.iid}"
+ should_not_see_todo "John Doe assigned issue ##{issue.iid}"
end
- def should_see_task(position, title, body, pending = true)
- page.within(".task:nth-child(#{position})") do
+ def should_see_todo(position, title, body, pending = true)
+ page.within(".todo:nth-child(#{position})") do
expect(page).to have_content title
expect(page).to have_content body
@@ -102,7 +102,7 @@ class Spinach::Features::DashboardTasks < Spinach::FeatureSteps
end
end
- def should_not_see_task(title)
+ def should_not_see_todo(title)
expect(page).not_to have_content title
end
diff --git a/features/steps/shared/paths.rb b/features/steps/shared/paths.rb
index 112ace342f0..f4df4874d2f 100644
--- a/features/steps/shared/paths.rb
+++ b/features/steps/shared/paths.rb
@@ -103,8 +103,8 @@ module SharedPaths
visit dashboard_groups_path
end
- step 'I visit dashboard task queue page' do
- visit dashboard_tasks_path
+ step 'I visit dashboard todos page' do
+ visit dashboard_todos_path
end
step 'I should be redirected to the dashboard groups page' do