Spec updates
This commit is contained in:
parent
31fea92295
commit
6a3d8ac207
2 changed files with 6 additions and 8 deletions
|
@ -33,7 +33,7 @@ feature 'Issue filtering by Milestone', feature: true do
|
||||||
visit_issues(project)
|
visit_issues(project)
|
||||||
filter_by_milestone(Milestone::Upcoming.title)
|
filter_by_milestone(Milestone::Upcoming.title)
|
||||||
|
|
||||||
expect(page).to have_css('.issue .title', count: 1)
|
expect(page).to have_css('.issue', count: 1)
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'should not show issues in past' do
|
it 'should not show issues in past' do
|
||||||
|
@ -44,7 +44,7 @@ feature 'Issue filtering by Milestone', feature: true do
|
||||||
visit_issues(project)
|
visit_issues(project)
|
||||||
filter_by_milestone(Milestone::Upcoming.title)
|
filter_by_milestone(Milestone::Upcoming.title)
|
||||||
|
|
||||||
expect(page).to have_css('.issue .title', count: 0)
|
expect(page).to have_css('.issue', count: 0)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ feature 'Issue filtering by Milestone', feature: true do
|
||||||
visit_issues(project)
|
visit_issues(project)
|
||||||
filter_by_milestone(milestone.title)
|
filter_by_milestone(milestone.title)
|
||||||
|
|
||||||
expect(page).to have_css('.issue .title', count: 1)
|
expect(page).to have_css('.issue', count: 1)
|
||||||
end
|
end
|
||||||
|
|
||||||
def visit_issues(project)
|
def visit_issues(project)
|
||||||
|
@ -64,8 +64,6 @@ feature 'Issue filtering by Milestone', feature: true do
|
||||||
|
|
||||||
def filter_by_milestone(title)
|
def filter_by_milestone(title)
|
||||||
find(".js-milestone-select").click
|
find(".js-milestone-select").click
|
||||||
sleep 0.5
|
|
||||||
find(".milestone-filter .dropdown-content a", text: title).click
|
find(".milestone-filter .dropdown-content a", text: title).click
|
||||||
sleep 1
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -33,7 +33,7 @@ feature 'Merge Request filtering by Milestone', feature: true do
|
||||||
visit_merge_requests(project)
|
visit_merge_requests(project)
|
||||||
filter_by_milestone(Milestone::Upcoming.title)
|
filter_by_milestone(Milestone::Upcoming.title)
|
||||||
|
|
||||||
expect(page).to have_css('.merge-request-title', count: 1)
|
expect(page).to have_css('.merge-request', count: 1)
|
||||||
end
|
end
|
||||||
|
|
||||||
it 'should not show issues in past' do
|
it 'should not show issues in past' do
|
||||||
|
@ -44,7 +44,7 @@ feature 'Merge Request filtering by Milestone', feature: true do
|
||||||
visit_merge_requests(project)
|
visit_merge_requests(project)
|
||||||
filter_by_milestone(Milestone::Upcoming.title)
|
filter_by_milestone(Milestone::Upcoming.title)
|
||||||
|
|
||||||
expect(page).to have_css('.merge-request-title', count: 0)
|
expect(page).to have_css('.merge-request', count: 0)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -55,7 +55,7 @@ feature 'Merge Request filtering by Milestone', feature: true do
|
||||||
visit_merge_requests(project)
|
visit_merge_requests(project)
|
||||||
filter_by_milestone(milestone.title)
|
filter_by_milestone(milestone.title)
|
||||||
|
|
||||||
expect(page).to have_css('.merge-request-title', count: 1)
|
expect(page).to have_css('.merge-request', count: 1)
|
||||||
end
|
end
|
||||||
|
|
||||||
def visit_merge_requests(project)
|
def visit_merge_requests(project)
|
||||||
|
|
Loading…
Reference in a new issue