diff options
author | Eric Eastwood <contact@ericeastwood.com> | 2017-03-22 19:26:47 +0300 |
---|---|---|
committer | Eric Eastwood <contact@ericeastwood.com> | 2017-03-29 22:12:12 +0300 |
commit | 5107f6b304fef473cd8ad04287f14fd3e9747674 (patch) | |
tree | db733697cf4e649b78161cd55b0437be922d5eca /spec/features/issues_spec.rb | |
parent | 6460489babe3cd25358800804f6befc1bd242f22 (diff) |
Fix linking to new issue with selected template
Fix https://gitlab.com/gitlab-org/gitlab-ce/issues/26595
Diffstat (limited to 'spec/features/issues_spec.rb')
-rw-r--r-- | spec/features/issues_spec.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/spec/features/issues_spec.rb b/spec/features/issues_spec.rb index a58aedc924e..7afceb88cf9 100644 --- a/spec/features/issues_spec.rb +++ b/spec/features/issues_spec.rb @@ -13,6 +13,13 @@ describe 'Issues', feature: true do user2 = create(:user) project.team << [[@user, user2], :developer] + + project.repository.create_file( + @user, + '.gitlab/issue_templates/bug.md', + 'this is a test "bug" template', + message: 'added issue template', + branch_name: 'master') end describe 'Edit issue' do @@ -600,6 +607,16 @@ describe 'Issues', feature: true do expect(page.find_field("issue_description").value).to match /\n\n$/ end end + + context 'form filled by URL parameters' do + before do + visit new_namespace_project_issue_path(project.namespace, project, issuable_template: 'bug') + end + + it 'fills in template' do + expect(find('.js-issuable-selector .dropdown-toggle-text')).to have_content('bug') + end + end end describe 'new issue by email' do |