Skip to main content

Bitbucket Pipeline Integration with SmartUI

Bitbucket is a web-based version control repository hosting service owned by Atlassian. It is primarily designed for development teams to manage their code, collaborate on projects, and streamline their workflows.

This document will show you how to integrate Bitbucket Pipeline with SmartUI to shorten your test cycles.

Steps to Integrate Bitbucket Pipeline with SmartUI

To integrate Bitbucket Pipeline with SmartUI, follow the below steps. You can use your own project to configure and test it. For demo purposes, we are using the sample repository.

Sample repo

Download or Clone the code sample from the LambdaTest GitHub repository to run the tests on the SmartUI.

Image View on GitHub

Step 1: Setup your Projects and Repository in Bitbucket

  • Click on the Create >> Project.
  • Enter your Project details and click on Create Project.
Create New Project
  • Now click on the Create Repository button. You can either create a new repository or import your existing repository.
Create New Project

Step 2: Create a New Workflow

  • Navigate to the Deployment section. Select your required template for CI/CD workflow file. For the demo we are using the Test template.
  • Now, write your workflow YAML file. Here is the sample file for your reference.
  • Commit this yaml file in your repository and make the required changes in your code to automatically trigger the pipeline.
bitbucket-pipelines.yml
loading...
tip

You can also store your LT_USERNAME, LT_ACCESS_KEY and PROJECT_TOKEN as secrets in your Bitbucket project repository.

Step 3: Check the output

Create New Project

Best Practices

Secret Management

  • Never commit credentials to repository
  • Use Bitbucket Pipelines Variables for all sensitive data
  • Rotate secrets regularly
  • Use different secrets for different environments

Troubleshooting

Issue: Pipeline Fails with "Variable Not Found"

Symptoms: Pipeline fails with error about missing variables

Possible Causes:

  • Variables not created in Bitbucket repository
  • Variable names don't match
  • Variables not accessible to pipeline

Solutions:

  1. Verify variables exist in repository settings:

    • Go to Repository Settings → Pipelines → Repository variables
    • Check LT_USERNAME, LT_ACCESS_KEY, and PROJECT_TOKEN exist
  2. Ensure variable names match exactly (case-sensitive)

  3. Check variable scope (repository, workspace, or deployment level)

  4. Verify variables are secured if needed

Additional Resources

Test across 3000+ combinations of browsers, real devices & OS.

Book Demo

Help and Support

Related Articles