This section guides you through deploying Bitbucket as a CI/CD tool in your environment so that you can observe the test runs from the CI Dashboard view and view links to the CI Dashboard view in Slack and Jenkins.
To help you get started and as a point of reference, we have made a sample project available here.
Click a step to view details.
To sign up and try Bitbucket for free, follow the steps at https://bitbucket.org/account/signup.
- Log in to Bitbucket.
On your own work tab, click Create repository.
- In a terminal window, do the following:
- Switch to your repository's directory.
Connect your existing repository to Bitbucket with the following git commands:Copy
git remote add origin https://<username>@bitbucket.org/<username>/<repo name>.git
git add .
git commit -m "first commit" git push -u origin master
<username>refers to your Bitbucket username and
<repo name>refers to the name of your repo in Bitbucket.
- On the Pipelines tab, do one of the following:
- Validate your
pipeline.ymlfile. You can use this validator.
On the Settings tab, under Repository variables, use the Name and Value fields to provide the following information. Make sure to select the Secured checkbox for each name/value pair to securely store the values from the console.
The username for your Perfecto cloudNote
You may want to skip securing the name of your Perfecto cloud. If you do secure it, the name will not show up in the Single Test Report URL that appears in the console.
Your Perfecto security tokenTo generate a security token:
In the Perfecto UI at <YourCloud>.app.perfectomobile.com (where YourCloudis your actual cloud name, such asmobilecloud), click your user name and select My security token.
In the My security token form, click Generate Security Token.
Click Copy to clipboard. Then paste it into any scripts that you want to run with Perfecto.
- Click Close.
- The slack_hook to store the Incoming Webhook URL of your Slack app (For more information on integrating with Slack, see this Slack article.)
- Optionally, manually trigger the pipeline as follows:
- To schedule jobs in Bitbucket, see this Bitbucket article.
Review the results of the pipeline execution in the CI Dashboard view of the Perfecto UI.
With Slack integration, you receive a link to the CI Dashboard in a Slack notification.
To view the pipeline execution in our sample project, click here.