> ## Documentation Index
> Fetch the complete documentation index at: https://dshtauri.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Testing and quality checks

> Run frontend, Rust, and cross-platform checks before submitting a change.

Run the fastest relevant checks while developing. Before a pull request, add real-process and platform tests for the behavior you changed.

## JavaScript checks

Prepare workspace build outputs on a fresh checkout. See the [CI workflow](https://github.com/dsh-tauri/deepseek-harness-desktop/blob/main/.github/workflows/ci.yml) for dependency and E2E setup.

```bash theme={null}
pnpm build:plugins
pnpm typecheck
pnpm lint
node node_modules/vitest/vitest.mjs run --project unit
```

| Script | Scope | Additional preparation |
| - | - | - |
| `test:unit` | Vitest unit and component tests | Shared-package and plugin build outputs |
| `test:e2e:plugin` | L2: real Harness and Chromium | Plugin outputs, Chromium, isolated Harness runtime |
| `test:e2e:desktop` | L3: real Tauri window and WebDriver | Debug binary with embedded frontend; current CI runs on Windows |

Use explicit `run` commands as required by the repository's test protocol:

```bash theme={null}
node node_modules/vitest/vitest.mjs run --project plugin
node node_modules/vitest/vitest.mjs run --project desktop
```

`pnpm test` selects all three projects, not just unit tests. Use isolated test directories and let tests manage their services; never reuse a release service.

## Rust checks

From `src-tauri/`:

```bash theme={null}
cargo check --locked
cargo test --all-features --locked
```

The Rust CI matrix covers Ubuntu 22.04, macOS 14, and Windows with the prerequisites in [Development setup](https://dshtauri.mintlify.site/en/development/setup.md).

## Manual scenarios

* Installation and recovery: first download, interruption, retry, local-core reuse, and failed updates.
* Service lifecycle: health, port fallback and return, restart, shutdown, logs, and release/debug isolation.
* Profiles and plugins: profile switching, preset or community plugin changes, and built-in bridge recovery.
* Platform packaging: Windows installers, macOS signing/notarization verification, Linux `.deb`, AppImage, and a Wayland smoke test.

## Before opening a pull request

* Add or update tests for behavior changes.
* Confirm no secrets, local paths, or generated application data are committed.
* Test both release-sensitive and debug-sensitive path or port changes.
* Document user-visible changes in both documentation languages.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.