@@ -839,9 +839,10 @@ var _ = Describe("HCP MachinePool", ci.Day2, ci.FeatureMachinepool, func() {
839839 By ("Try to create a nodepool with version < CP version-2" )
840840 throttleVersion := fmt .Sprintf ("%v.%v.0" , currentSemVer .Major (), currentSemVer .Minor ()- 2 )
841841 versions = cms .GetHcpLowerVersions (cms .RHCSConnection , throttleVersion , profileHandler .Profile ().GetChannelGroup ())
842+ versions = cms .SortVersions (versions )
842843 if len (versions ) > 0 {
843844 validateMPArgAgainstErrorSubstrings (mpName , func (args * exec.MachinePoolArgs ) {
844- args .OpenshiftVersion = helper .StringPointer (versions [0 ].RawID )
845+ args .OpenshiftVersion = helper .StringPointer (versions [len ( versions ) - 1 ].RawID )
845846 }, "must be no less than 2 minor versions behind the Control Plane version" )
846847 } else {
847848 Logger .Info ("No version < CP version - 2 found to test against" )
@@ -850,7 +851,7 @@ var _ = Describe("HCP MachinePool", ci.Day2, ci.FeatureMachinepool, func() {
850851 By ("Try to create a nodepool with not supported version" )
851852 validateMPArgAgainstErrorSubstrings (mpName , func (args * exec.MachinePoolArgs ) {
852853 args .OpenshiftVersion = helper .StringPointer ("4.10.67" )
853- }, "must be greater than the lowest supported version" )
854+ }, "must be greater than the minimal supported version" )
854855
855856 By ("Try to create a nodepool with wrong version" )
856857 validateMPArgAgainstErrorSubstrings (mpName , func (args * exec.MachinePoolArgs ) {
0 commit comments