Commit 024c0f77 authored by Jacob Schatz's avatar Jacob Schatz Committed by Clement Ho

Merge branch 'enable-autocomplete-on-project-snippets' into 'master'

Enable autocomplete on project snippets

Closes #33911

See merge request !12286
parent 8fed6188
......@@ -219,6 +219,8 @@ import initSettingsPanels from './settings_panels';
case 'projects:snippets:edit':
case 'projects:snippets:create':
case 'projects:snippets:update':
new gl.GLForm($('.snippet-form'), true);
break;
case 'snippets:new':
case 'snippets:edit':
case 'snippets:create':
......
......@@ -26,5 +26,19 @@ describe 'Project snippets', feature: true do
expect(page).to have_content(snippets[1].title)
end
end
context 'when submitting a note' do
before do
login_as :admin
visit namespace_project_snippet_path(project.namespace, project, snippets[0])
end
it 'should have autocomplete' do
find('#note_note').native.send_keys('')
fill_in 'note[note]', with: '@'
expect(page).to have_selector('.atwho-view')
end
end
end
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment