I recently came across a PR build which for some reason was only checking if code merge is possible and was not really building on merged code.
I always had an understanding that the PR build should do following (assuming a feature
branch is being merged to master
)
- checkout the destination branch (master)
- pull/merge the source branch (feature)
- make sure merge has no issues [OR Fail]
- trigger necessary steps of build i.e. compile, test etc.
- clean up
I tried searching on internet on what are the steps followed during PR build but could not find anything clear. I wanted to check with this community if this understanding is correct OR I had a wrong understanding of PR builds all along.
EDIT:
We are using Bitbucket Branch Source Plugin
master
without issues and leaves it open. A few hours later someone else completes a PR intomaster
that now causes the first PR to have conflicts. This "build" could run, see that the source branch can no longer be merged cleanly intomaster
, and notify someone that the PR source branch needs updating. Not all "builds" need to actually "build" something. You could have 5 different "builds" pointing to the same PR, all doing different things.