-
João Alexandre Cunha authored
All this changes only impact tests. Our specs shouldn't depend on whether the tests are run on the master branch or on a stable release branch, or a tag branch. In the master branch gitlabVersion resolves to master but on stable branches it will resolve to a semVer. The solution proposed here is to: - Update HelmTemplate.defaults helper to include global.gitlabVersion:"v42.0.0". - Update all usages of this helper to merge the values using deep_merge instead of merge when customizing values. - Fix the HelmTemplate.with_defaults(yaml) to override the defaults with the passed yaml and not the other way arround. - Adapt the tests that actually test not passing gitlabVersion to not use the HelmTemplate.defaults, but to use only the HelmTemplate.certmanager_issuer which is the only default it needs to be tested. For this specific test we'll keep it dependent on the branch, but we have a preexisting fetch_default_gitlab_version helper method that takes care of it. Additional cosmetic updates: - Use deep_merge! instead of deep_merge for consistency - Rubocop also fixed a couple of identations
João Alexandre Cunha authoredAll this changes only impact tests. Our specs shouldn't depend on whether the tests are run on the master branch or on a stable release branch, or a tag branch. In the master branch gitlabVersion resolves to master but on stable branches it will resolve to a semVer. The solution proposed here is to: - Update HelmTemplate.defaults helper to include global.gitlabVersion:"v42.0.0". - Update all usages of this helper to merge the values using deep_merge instead of merge when customizing values. - Fix the HelmTemplate.with_defaults(yaml) to override the defaults with the passed yaml and not the other way arround. - Adapt the tests that actually test not passing gitlabVersion to not use the HelmTemplate.defaults, but to use only the HelmTemplate.certmanager_issuer which is the only default it needs to be tested. For this specific test we'll keep it dependent on the branch, but we have a preexisting fetch_default_gitlab_version helper method that takes care of it. Additional cosmetic updates: - Use deep_merge! instead of deep_merge for consistency - Rubocop also fixed a couple of identations
Loading