require'spec_helper'describeGitlab::Upgraderdolet(:upgrader){Gitlab::Upgrader.new}let(:current_version){Gitlab::VERSION}describe'current_version_raw'doit{upgrader.current_version_raw.should==current_version}enddescribe'latest_version?'doit'should be true if newest version'doupgrader.stub(latest_version_raw: current_version)upgrader.latest_version?.shouldbe_trueendenddescribe'latest_version_raw'doit'should be latest version for GitLab 5'doupgrader.stub(current_version_raw: "5.3.0")upgrader.latest_version_raw.should=="v5.4.2"endendend