summaryrefslogtreecommitdiff
path: root/spec/requests/api/variables_spec.rb
diff options
context:
space:
mode:
authorMatija Čupić <matteeyah@gmail.com>2018-02-05 18:42:58 +0100
committerMatija Čupić <matteeyah@gmail.com>2018-02-05 20:15:06 +0100
commit5f127babcc22651754b512fbb6f3ca4559c96225 (patch)
treedf56e7efe0fdd6cecf814c4fd65571ec1c1fe269 /spec/requests/api/variables_spec.rb
parent0ccbc6515e4c08ce77af6c8a82ead52a961ce2f3 (diff)
downloadgitlab-ce-5f127babcc22651754b512fbb6f3ca4559c96225.tar.gz
Fix API variable specs
Diffstat (limited to 'spec/requests/api/variables_spec.rb')
-rw-r--r--spec/requests/api/variables_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/requests/api/variables_spec.rb b/spec/requests/api/variables_spec.rb
index 79ee6c126f6..62215ea3d7d 100644
--- a/spec/requests/api/variables_spec.rb
+++ b/spec/requests/api/variables_spec.rb
@@ -122,12 +122,12 @@ describe API::Variables do
describe 'PUT /projects/:id/variables/:key' do
context 'authorized user with proper permissions' do
it 'updates variable data' do
- initial_variable = project.variables.first
+ initial_variable = project.variables.reload.first
value_before = initial_variable.value
put api("/projects/#{project.id}/variables/#{variable.key}", user), value: 'VALUE_1_UP', protected: true
- updated_variable = project.variables.first
+ updated_variable = project.variables.reload.first
expect(response).to have_gitlab_http_status(200)
expect(value_before).to eq(variable.value)