0

I have build configuration in TeamCity with automated tests. I want to run this build configuration in the loop: when one build was finished, new build is started. I can not configure 'Finish Build Trigger', because it is necessary to create snapshot dependencies for it, but I want to run tests for the latest version of code each time. How I can configure such loop?

user1590561
  • 583
  • 2
  • 6
  • 17

1 Answers1

3

From your question:

I can not configure 'Finish Build Trigger', because it is necessary to create snapshot dependencies for it

Actually, it is NOT nescesary to have a snapshot dependency for a "Finish Build Trigger". You will, however, get a warning saying that "There is not snapshot dependency on the selected build configuration", but that will not keep you from triggering on a selected build.

From Teamcity Documentation:

If there is no snapshot dependency, the following limitations exist:

  • it is likely that a build of the build configuration being triggered will not have the same revisions as the finished build even if both configurations have the same VCS settings
  • if a build configuration with the Finish Build Trigger has an artifact dependency on the last finished build of the build
    configuration specified in the trigger settings, there is no
    guarantee that artifacts of a build which caused build triggering
    will be used, because, while the triggered build sits in the build
    queue, another build may finish
  • the build triggered by the Finish Build Trigger will always be triggered in the default branch even if the finished build has some
    other branch

I do recommend to select the "Trigger after successful build only" checkbox since you are running unit tests.

Wilmer SH
  • 1,417
  • 12
  • 20