Commit cdabe631 authored by Dennis Tang's avatar Dennis Tang

Change GitHub service integration token input to password

parent 5a1e492b
---
title: Change GitHub service integration token input to password
merge_request:
author:
type: security
...@@ -38,7 +38,7 @@ class GithubService < Service ...@@ -38,7 +38,7 @@ class GithubService < Service
def fields def fields
[ [
{ type: 'text', { type: 'password',
name: "token", name: "token",
required: true, required: true,
placeholder: "e.g. 8d3f016698e...", placeholder: "e.g. 8d3f016698e...",
......
...@@ -39,6 +39,10 @@ describe 'User activates GitHub Service' do ...@@ -39,6 +39,10 @@ describe 'User activates GitHub Service' do
expect(page).to have_content('GitHub activated.') expect(page).to have_content('GitHub activated.')
end end
it 'renders a token field of type `password` for masking input' do
expect(find('#service_token')['type']).to eq('password')
end
context 'with pipelines', :js do context 'with pipelines', :js do
let(:pipeline) { create(:ci_pipeline) } let(:pipeline) { create(:ci_pipeline) }
let(:project) { create(:project, ci_pipelines: [pipeline])} let(:project) { create(:project, ci_pipelines: [pipeline])}
......
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