Remove "mystery guest" from Milestone filtering features
This commit is contained in:
parent
cf7c57aaf5
commit
098ad0a5b4
2 changed files with 18 additions and 26 deletions
|
@ -1,34 +1,30 @@
|
|||
require 'spec_helper'
|
||||
require 'rails_helper'
|
||||
|
||||
feature 'Issue filtering by Milestone', feature: true do
|
||||
include Select2Helper
|
||||
|
||||
let(:project) { create(:project) }
|
||||
|
||||
before do
|
||||
login_as(:admin)
|
||||
end
|
||||
|
||||
scenario 'User filters by Issues without a Milestone', js: true do
|
||||
scenario 'filters by no Milestone', js: true do
|
||||
project = create(:project, :public)
|
||||
create(:issue, project: project)
|
||||
|
||||
visit_issues
|
||||
visit_issues(project)
|
||||
filter_by_milestone(Milestone::None.title)
|
||||
|
||||
expect(page).to have_css('.issue-title', count: 1)
|
||||
end
|
||||
|
||||
scenario 'User filters by Issues with a specific Milestone', js: true do
|
||||
scenario 'filters by a specific Milestone', js: true do
|
||||
project = create(:project, :public)
|
||||
milestone = create(:milestone, project: project)
|
||||
create(:issue, project: project, milestone: milestone)
|
||||
|
||||
visit_issues
|
||||
visit_issues(project)
|
||||
filter_by_milestone(milestone.title)
|
||||
|
||||
expect(page).to have_css('.issue-title', count: 1)
|
||||
end
|
||||
|
||||
def visit_issues
|
||||
def visit_issues(project)
|
||||
visit namespace_project_issues_path(project.namespace, project)
|
||||
end
|
||||
|
||||
|
|
|
@ -1,34 +1,30 @@
|
|||
require 'spec_helper'
|
||||
require 'rails_helper'
|
||||
|
||||
feature 'Merge Request filtering by Milestone', feature: true do
|
||||
include Select2Helper
|
||||
|
||||
let(:project) { create(:project) }
|
||||
scenario 'filters by no Milestone', js: true do
|
||||
project = create(:project, :public)
|
||||
create(:merge_request, :with_diffs, source_project: project)
|
||||
|
||||
before do
|
||||
login_as(:admin)
|
||||
end
|
||||
|
||||
scenario 'User filters by Merge Requests without a Milestone', js: true do
|
||||
create(:merge_request, :simple, source_project: project)
|
||||
|
||||
visit_merge_requests
|
||||
visit_merge_requests(project)
|
||||
filter_by_milestone(Milestone::None.title)
|
||||
|
||||
expect(page).to have_css('.merge-request-title', count: 1)
|
||||
end
|
||||
|
||||
scenario 'User filters by Merge Requests with a specific Milestone', js: true do
|
||||
scenario 'filters by a specific Milestone', js: true do
|
||||
project = create(:project, :public)
|
||||
milestone = create(:milestone, project: project)
|
||||
create(:merge_request, :simple, source_project: project, milestone: milestone)
|
||||
create(:merge_request, :with_diffs, source_project: project, milestone: milestone)
|
||||
|
||||
visit_merge_requests
|
||||
visit_merge_requests(project)
|
||||
filter_by_milestone(milestone.title)
|
||||
|
||||
expect(page).to have_css('.merge-request-title', count: 1)
|
||||
end
|
||||
|
||||
def visit_merge_requests
|
||||
def visit_merge_requests(project)
|
||||
visit namespace_project_merge_requests_path(project.namespace, project)
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue