# Merge test files that cover the same unit from three angles

One unit covered by three files written by three people, merged into a single suite.

Category: Test suite consolidation
Source: https://letsship.ai/use-cases/merge-test-files-covering-one-unit
Published: 2026-08-25

## Goal

Merge several test files covering the same unit into one suite without losing an assertion.

## Acceptance criteria

- Every assertion from the original files survives in the merged suite
- The merged file is organised by behaviour rather than by who wrote what
- Runtime is measured before and after
- The old files are deleted, not left empty

## What lands as proof

An assertion count that matches, and a runtime measurement showing what the merge saved.

## Prompt

Copy this to an agent to open the ticket:

```text
Create a Linear issue in my team and assign it to the SHIP agent.

Title: Merge the {unit} test files into one suite

Description: Merge several test files covering the same unit into one suite without losing an assertion.

Acceptance criteria:
- Every assertion from the original files survives in the merged suite
- The merged file is organised by behaviour rather than by who wrote what
- Runtime is measured before and after
- The old files are deleted, not left empty

Before you create the issue, find a unit in this repository covered by more than one test file and replace {unit} with it.
```

## Questions

### What does the agent actually change?

The ticket is scoped to one outcome: merge several test files covering the same unit into one suite without losing an assertion. Work that serves that outcome is in scope, and anything outside it is left for a separate ticket, so the pull request stays reviewable.

### How do I know the work is done?

The pull request carries the evidence, not only the diff. Here that means same assertions, fewer files, runtime measured before and after, so a reviewer can confirm the result without reproducing the work locally.

### How much oversight does this need?

None is required before the run starts. Every claim this ticket makes can be checked by machine, so the agent works straight through and a person reviews the finished pull request like any other.
