# Pipeline Integration

Learn how to integrate Unit Tests with Buddy pipelines using the Collect tests results feature.

After creating a test suite, you can use it in a pipeline.

## Pipeline configuration

1. Add a Build action (e.g., Node) to your pipeline
2. In the **commands** section, on the right side, you'll find the **Collect test** results button
3. Click **Collect test results** to open the configuration.

![Pipeline Action - Collect Tests Results](/docs/tests/unit-tests/unit-tests-pipeline-1.png 640x400)

## Framework and suite selection
In the popup: 

- Select the created Suite from the dropdown list
- Choose the Framework instruction (e.g., Jest, Playwright, Cypress)
- Follow the provided instructions

![Collect Tests Results Configuration](/docs/tests/unit-tests/unit-tests-pipeline-2.png 640x500)

## Finalizing configuration

1. Click **Set configuration** - the selected Suite will appear in the **Collect test results** button.
2. Add the commands in the **commands** section according to the instructions displayed in the popup.

![Pipeline Action with Configured Test Suite](/docs/tests/unit-tests/unit-tests-pipeline-3.png 640x400)

After running the pipeline, the tests will be executed, and the results will be visible in the **Unit Tests** section in the project sidebar, where you can select your Suite. You can also access them directly from the execution summary.

![Unit Tests in run view](/docs/tests/unit-tests/unittest-execution.png 640x611)

<Hint type="info">
You don’t need to manually set the `BUDDY_UT_TOKEN` environment variable in the pipeline - Buddy automatically uses the token assigned to the selected Suite.
</Hint>

You can find detailed information about viewing test results in the [Results & Analytics](/docs/tests/unit-tests/results-and-analytics.md) section.


---
Original source: https://buddy.works/docs/tests/unit-tests/pipeline-integration