Two-way synchronization
In the majority of the cases, the scenarios are changed in the feature files. This ensures that all necessary automation infrastructure (eg. step definitions) are also adapted when a change has been performed in the scenario.
In some special cases, it might be useful to be able to make small changes in the test cases synchronized from the scenarios directly in TFS. Synchronizing such changes back to the feature files is a complex process and it is only recommended if it's really required.
SpecSync provides a feature for two-way synchronization.
To use the two-way synchronization, the --backSync
option has to be specified. With this option, SpecSync will check if there have been any changes in the test case since the last synchronization and updates the local feature file if necessary. It is also able to detect if there have been conflicting changes (both the feature file and the test case have been changed) and allows to choose between the changes.
With the --backSyncNewTestCases
option, the new test cases added to the specified test suite in TFS are synchronized back to new feature files.
Note: SpecSync cannot ensure that the updated feature files are commited to the source control. If these changes are not committed, and someone else is also performing the synchronization, the changes will be synchronized multiple times causing various conflicts. We recommend to ensure that there are no parallel back synchronization performed. This can be ensured by specifying the --buildServerMode
option for the other clients.