# Testing

Always run the test suite locally before opening a PR, and add test cases for any new feature or fix.

Canonical URL: https://docs.polyhammer.com/blender-addons/character-dna/0.15.1/contributing/testing
Product: character-dna
Version: 0.15.1
Channel: production
Updated: 2026-11-21T13:45:20Z
Documentation source: initial main snapshot approved 2026-11-21T13:45:20Z
Documentation commit: 3533cd1260a9bd4b2806aaa4c64ead70766a1674
Release tag commit: 71125e9857db2b5a8ffa9426cc1f769d13017fd5
Owner-approved migration baseline: use current main documentation for the current stable release once; all subsequent releases use their tag snapshots.

Always run the test suite locally before opening a PR, and add test cases for any new feature or fix.

## Running the Test Suite [#running-the-test-suite]

With the project synced (`uv sync`):

```shell
uv run pytest
```

![Running the tests](/docs-assets/character-dna/1266b506df4569026b7751ea740d32b5ea2fabb12ae380687e89495ef772c326/images/contributing/testing/1.gif)

## With Coverage [#with-coverage]

Use the **Pytest: With Coverage** VS Code task, or run pytest with the coverage flags against the addon package:

```shell
uv run pytest --cov=src/addons/character_dna --cov-report=html:reports/coverage/html
```

Open `reports/coverage/html/index.html` to review coverage.

<Callout type="info" title="Note">
New features require accompanying unit tests to be approved. Keep tests close to the behavior they cover and prefer testing through public entry points.
</Callout>
