gitlab-org--gitlab-foss/spec/features/projects/sub_group_issuables_spec.rb
Rémy Coutable aa0d8b4cba Merge branch 'frozen_string_spec_features' into 'master'
Add frozen_string_literal to spec/features

See merge request gitlab-org/gitlab-ce!31131
2019-07-29 08:29:43 +00:00

33 lines
879 B
Ruby

# frozen_string_literal: true
require 'spec_helper'
describe 'Subgroup Issuables', :js do
let!(:group) { create(:group, name: 'group') }
let!(:subgroup) { create(:group, parent: group, name: 'subgroup') }
let!(:project) { create(:project, namespace: subgroup, name: 'project') }
let(:user) { create(:user) }
before do
project.add_maintainer(user)
sign_in user
end
it 'shows the full subgroup title when issues index page is empty' do
visit project_issues_path(project)
expect_to_have_full_subgroup_title
end
it 'shows the full subgroup title when merge requests index page is empty' do
visit project_merge_requests_path(project)
expect_to_have_full_subgroup_title
end
def expect_to_have_full_subgroup_title
title = find('.breadcrumbs-links')
expect(title).to have_content 'group subgroup project'
end
end