debian-mirror-gitlab/spec/features/issues/group_label_sidebar_spec.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
624 B
Ruby
Raw Normal View History

2019-10-12 21:52:04 +05:30
# frozen_string_literal: true
2019-12-04 20:38:33 +05:30
require 'spec_helper'
2017-08-17 22:00:37 +05:30
2020-06-23 00:09:42 +05:30
RSpec.describe 'Group label on issue' do
2020-11-24 15:15:51 +05:30
it 'renders link to the project issues page', :js do
2017-08-17 22:00:37 +05:30
group = create(:group)
2017-09-10 17:25:29 +05:30
project = create(:project, :public, namespace: group)
2017-08-17 22:00:37 +05:30
feature = create(:group_label, group: group, title: 'feature')
issue = create(:labeled_issue, project: project, labels: [feature])
2017-09-10 17:25:29 +05:30
label_link = project_issues_path(project, label_name: [feature.name])
2017-08-17 22:00:37 +05:30
2017-09-10 17:25:29 +05:30
visit project_issue_path(project, issue)
2017-08-17 22:00:37 +05:30
link = find('.issuable-show-labels a')
2020-11-24 15:15:51 +05:30
expect(CGI.unescape(link[:href])).to include(CGI.unescape(label_link))
2017-08-17 22:00:37 +05:30
end
end