diff options
author | Krasimir Angelov <kangelov@gitlab.com> | 2019-06-06 14:08:01 +0300 |
---|---|---|
committer | Krasimir Angelov <kangelov@gitlab.com> | 2019-06-06 14:22:50 +0300 |
commit | 52673a916df0f759262afa1aaa230f7d62efd554 (patch) | |
tree | 0635538d8bf562e914c0bb44f1580cf9d56aa5f3 /spec/models/project_ci_cd_setting_spec.rb | |
parent | ad9ae16d8a44dd2523bd6e6109db9fe2da45d3a5 (diff) |
Forks get default_git_depth 0 if the origin is nil
If the origin project has no default_git_depth set (i.e. nil) set the
fork's default_git_depth to 0
Diffstat (limited to 'spec/models/project_ci_cd_setting_spec.rb')
-rw-r--r-- | spec/models/project_ci_cd_setting_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/models/project_ci_cd_setting_spec.rb b/spec/models/project_ci_cd_setting_spec.rb index 80f75f45e43..c5a4c242b70 100644 --- a/spec/models/project_ci_cd_setting_spec.rb +++ b/spec/models/project_ci_cd_setting_spec.rb @@ -37,10 +37,10 @@ describe ProjectCiCdSetting do it 'does not set default value if present' do project = build(:project) - project.build_ci_cd_settings(default_git_depth: 42) + project.build_ci_cd_settings(default_git_depth: 0) project.save! - expect(project.reload.ci_cd_settings.default_git_depth).to eq(42) + expect(project.reload.ci_cd_settings.default_git_depth).to eq(0) end end end |