summaryrefslogtreecommitdiff
path: root/spec/requests/ci
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2017-02-14 19:17:36 +0800
committerLin Jen-Shin <godfat@godfat.org>2017-02-15 15:31:51 +0800
commit696a5da7fd78093567ae2bc7a795a38462dd7b3d (patch)
tree27a31a60b7112a41183f90b609e5f04322ec0891 /spec/requests/ci
parentd2d30cff552e08c4b7ec2b5e23acced8eb29cbcb (diff)
downloadgitlab-ce-696a5da7fd78093567ae2bc7a795a38462dd7b3d.tar.gz
ApplicationSetting.current doesn't work well in tests
Therefore we prefer `Gitlab::CurrentSettings.current_application_settings` and fix the tests by setting default_artifacts_expire_in to 0 to restore the original behaviour.
Diffstat (limited to 'spec/requests/ci')
-rw-r--r--spec/requests/ci/api/builds_spec.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/spec/requests/ci/api/builds_spec.rb b/spec/requests/ci/api/builds_spec.rb
index d85afdeab42..44f69bff30d 100644
--- a/spec/requests/ci/api/builds_spec.rb
+++ b/spec/requests/ci/api/builds_spec.rb
@@ -638,6 +638,8 @@ describe Ci::API::Builds do
end
before do
+ stub_application_setting(default_artifacts_expiration: 0)
+
post(post_url, post_data, headers_with_token)
end