All Collections
Behave Pro Server and Datacenter
Bitbucket Integration
Enable Bitbucket Hook to Reject Invalid Feature Files on Git Push
Enable Bitbucket Hook to Reject Invalid Feature Files on Git Push

Enable a pre-receive git hook on Bitbucket to reject the git commit when someone pushes an invalid feature(s)

Alan Parkinson avatar
Written by Alan Parkinson
Updated over a week ago

The Behave Pro for Bitbucket adds a new pre-receive hook into your Bitbucket instance can reject any git commits that contain invalid feature files. The Behave Pro for Jira can only accept sound feature files that contain no syntax errors. This pre-receive hook can be used to make sure that the feature synchronisation works without any problems.

First, navigate to the Bitbucket repository settings page and click on the "Hooks" in the left navigation menu.

Next, enable the "Behave Pro BitBucket Validate Features Pre Hook" in the "pre receive" section as shown below.

That's all.

Now, if you git push any features that contain syntax error, your command will fail, and you will be shown an error similar to the one in the screenshot below.

Did this answer your question?