Version control is available for users with Administrator and Contributor roles. Leapwork supports version control of both flows and sub-flows. Every time you click save, a version number is set, and Studio will prompt you to enter a short description of the changes made to the flow.
This description will be available from the version history in Leapwork, giving you both the possibility of reviewing changes made, and to restore and preview earlier versions of the flow.
Right-click on a flow or sub-flow to get access to Version History:
The Version History pane looks like this:
When in this module, you are enabled to take any of the following actions for each version:
Preview: Preview runs of previous versions are executed on the local machine allowing full insight into the details of the automation flow.
Restore: Roll back to a previous version of the flow and promote it to the current one.
Delete: This deletes a version of a flow. All versions are available for deletion, even the current one. Use with caution!
Previewing previous versions
By selecting the Preview option in the Version History pane, the previous version in question is opened in preview mode.
Restoring previous versions
When restoring, it is important to understand how Leapwork performs the restore. Leapwork lets you choose between three different restoring approaches:
Only Flow: This option only restores the flow's design in terms of intended steps and actions. However, Locators used in the building blocks are the most recent ones. This means, that if you made an update to a building block, e.g. captured a new element, it is the new element that continues to be used in the restored version.
Full Restore: This option not only restores the flow’s design to its previous version, it also re-apply previously captured Locators of that same version. If the application automated has changed since the creation date of the flow version being restored, this may cause the flow to fail. This is a good example of relevant information to put into the 'Save information' prompt; changes done within specific building blocks.
Full Copy: This will restore the flow’s design and make a copy of all used Locators.
Deleting previous flows
The Delete option in the Version History pane will delete the corresponding version data and remove it from version history.