Package com.piketec.jenkins.plugins.tpt
Class TptVersion
java.lang.Object
com.piketec.jenkins.plugins.tpt.TptVersion
- All Implemented Interfaces:
Serializable
TPT versions are named like "15" or "15u1" meaning release version 15, update release 1. For the
initial release "15u0" the update suffix "u0" is ommited. Milestone and release candidates are
named like 15M1b1234 or 15RC2b1234. This class encapsulates version and update number ignoring
the fact that milestone and release candidates exist. These are interpreted as final releses with
an update number of null.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal int
The main TPT versionfinal int
The update level -
Method Summary
Modifier and TypeMethodDescriptionstatic TptVersion
getVersion
(com.piketec.tpt.api.TptApi api) Read and parses the TPT version behind anTptApi
object.boolean
isAtLeast
(int major, int updateLevel) Checks if this version is greater or equals than the given version.boolean
To read and set test set conditions via API is available since 16u1.boolean
Test set condtions can be configured in TPT file since TPT 9.toString()
-
Field Details
-
major
public final int majorThe main TPT version -
updateLevel
public final int updateLevelThe update level
-
-
Method Details
-
getVersion
Read and parses the TPT version behind anTptApi
object.- Parameters:
api
- TheTptApi
object to which the version shall be determined.- Returns:
- The parsed version string of the
TptApi
object. - Throws:
RemoteException
- remote communication problem
-
isAtLeast
public boolean isAtLeast(int major, int updateLevel) Checks if this version is greater or equals than the given version.- Parameters:
major
- The minimal required major versionupdateLevel
- the minimal required update level- Returns:
- if this version is greater or equals than the given version
-
supportsTestCaseConditionAccess
public boolean supportsTestCaseConditionAccess()To read and set test set conditions via API is available since 16u1.- Returns:
true
if this TPT version supports test case condtion API access,false
otherwise.
-
supportsTestCaseConditions
public boolean supportsTestCaseConditions()Test set condtions can be configured in TPT file since TPT 9. Requirement sets can be used for test set conditions since TPT 11. For availabality via API seesupportsTestCaseConditionAccess()
.- Returns:
true
if this TPT version supports test case condtion in the TPT file,false
otherwise.
-
toString
-