How to do Post build scripts for pipeline?

After running our selenium test for our site, it would either generate a passing or failing report. If a test is already failing, then the build will already stop. Is there a way to do a post build script where it will run regardless if the build fails or pass and get the output of from the pipelines result?

1 answer

0 vote

Hi John,

There is a feature request for multiple steps that would allow you do this - you can follow it here:


As a workaround, you can add 

<test command> || true

to continue the build and execute a script.

The caveat of course is the build won't reflect the correct status.

Hi Davina,

I will try the work around you've suggest. My only concern is that the test is done so if it fails it won't continue deploying a bad code to the next environment. That's why a post build script would be great so we can setup getting of reports and sending it to people. Anyway, the multiple step might be the feature we really need for this. Hopefully we can have this asap. Thanks!

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Jun 12, 2018 in Bitbucket

Do you use any Atlassian products for your personal projects?

After spinning my wheels trying to get organized enough to write a book for National Novel Writing Month (NaNoWriMo) I took my affinity for Atlassian products from my work life and decided to tr...

23,667 views 26 12
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you