summaryrefslogtreecommitdiff
path: root/spec/controllers/groups/variables_controller_spec.rb
diff options
context:
space:
mode:
authorMatija Čupić <matteeyah@gmail.com>2018-01-23 19:34:06 +0100
committerMatija Čupić <matteeyah@gmail.com>2018-02-05 18:58:17 +0100
commitdcc23530bd1e2bd1600bd523c90c040f84f8c354 (patch)
tree34b4bb95fc9ca9b5c93e772bbb574343a4628d7d /spec/controllers/groups/variables_controller_spec.rb
parentcc2bed9283039db726f42184ea635f057534205f (diff)
downloadgitlab-ce-dcc23530bd1e2bd1600bd523c90c040f84f8c354.tar.gz
Remove redundant routes in Groups::VariablesController
Diffstat (limited to 'spec/controllers/groups/variables_controller_spec.rb')
-rw-r--r--spec/controllers/groups/variables_controller_spec.rb41
1 files changed, 0 insertions, 41 deletions
diff --git a/spec/controllers/groups/variables_controller_spec.rb b/spec/controllers/groups/variables_controller_spec.rb
index 294e712f45d..8570df15f34 100644
--- a/spec/controllers/groups/variables_controller_spec.rb
+++ b/spec/controllers/groups/variables_controller_spec.rb
@@ -9,47 +9,6 @@ describe Groups::VariablesController do
group.add_master(user)
end
- describe 'POST #create' do
- context 'variable is valid' do
- it 'shows a success flash message' do
- post :create, group_id: group, variable: { key: "one", value: "two" }
-
- expect(flash[:notice]).to include 'Variable was successfully created.'
- expect(response).to redirect_to(group_settings_ci_cd_path(group))
- end
- end
-
- context 'variable is invalid' do
- it 'renders show' do
- post :create, group_id: group, variable: { key: "..one", value: "two" }
-
- expect(response).to render_template("groups/variables/show")
- end
- end
- end
-
- describe 'POST #update' do
- let!(:variable) { create(:ci_group_variable, group: group) }
-
- context 'updating a variable with valid characters' do
- it 'shows a success flash message' do
- post :update, group_id: group,
- id: variable.id, variable: { key: variable.key, value: 'two' }
-
- expect(flash[:notice]).to include 'Variable was successfully updated.'
- expect(response).to redirect_to(group_variables_path(group))
- end
-
- it 'renders the action #show if the variable key is invalid' do
- post :update, group_id: group,
- id: variable.id, variable: { key: '?', value: variable.value }
-
- expect(response).to have_gitlab_http_status(200)
- expect(response).to render_template :show
- end
- end
- end
-
describe 'POST #save_multiple' do
let!(:variable) { create(:ci_group_variable, group: group) }