Class: Gitlab::QA::Support::GitlabUpgradePath
- Inherits:
-
Object
- Object
- Gitlab::QA::Support::GitlabUpgradePath
- Defined in:
- lib/gitlab/qa/support/gitlab_upgrade_path.rb
Instance Method Summary collapse
-
#fetch ⇒ Array<QA::Release>
Get upgrade path between releases.
-
#initialize(current_version, semver_component, edition) ⇒ GitlabUpgradePath
constructor
Get upgrade path between N - 1 and current version not including current release.
Constructor Details
#initialize(current_version, semver_component, edition) ⇒ GitlabUpgradePath
Get upgrade path between N - 1 and current version not including current release
15 16 17 18 19 20 21 |
# File 'lib/gitlab/qa/support/gitlab_upgrade_path.rb', line 15 def initialize(current_version, semver_component, edition) @version_info = GitlabVersionInfo.new(current_version, edition) @current_version = Gem::Version.new(current_version) @semver_component = semver_component @edition = edition @logger = Runtime::Logger.logger end |
Instance Method Details
#fetch ⇒ Array<QA::Release>
Get upgrade path between releases
Return array with only previous version for updates from previous minor, patch versions
28 29 30 31 32 33 34 35 |
# File 'lib/gitlab/qa/support/gitlab_upgrade_path.rb', line 28 def fetch return minor_upgrade_path unless major_upgrade? major_upgrade_path rescue GitlabVersionInfo::VersionNotFoundError logger.error("Failed to construct gitlab upgrade path") raise end |