Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Successful models to run unit tests as part of a deploy?

Bill Boulden April 29, 2014

I notice that all the test components I can use (NUnit parser, JUnit parser, etc) are not available in deploy projects in bamboo.

I'd really love to configure one or more deploy projects so that they deploy, then run unit tests, then the deploy is smart enough to self-rollback if they fail. I know how I could write my script that performs the deploy to do that itself, but it wouldn't exactly be very bamboo-aware. Like, have integration to the point where it would understand that it had to restore the previous successful build. Does anybody have good advice for how to write deploys so that they can run unit tests themselves and self-rollback? Can you share how you configured it to accomplish this task?

1 answer

1 vote
Deleted user July 21, 2014

Why do you need to run unit tests when deploying to different environments since you are testing the same artifact that you would have previously? True unit tests should be environmentally independent and the results should not change as long as the artifact does not change.

Or are these actually environmentally dependent integration tests that are running under a unit testing framework? The second scenario definitely makes sense and could be accomplished using command tasks to both run and parse the unit tests. You can still gate the release based on this, but you would need to rollback to the previous successful build. Someone may know of a way to redeploy the previous artifacts automatically, but I have yet to do so myself.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events