Open-Source Wikis

/

Tauri

/

Crates

/

tauri-driver

tauri-apps/tauri

tauri-driver

Active contributors: Chip, Lucas Fernandes Nogueira

Purpose

crates/tauri-driver is a small WebDriver-compatible binary used to drive Tauri apps from end-to-end test harnesses (Selenium / WebDriverIO / tauri-action). It speaks the WebDriver wire protocol on its own port and proxies into the platform's webview driver — WebKitWebDriver on Linux, msedgedriver.exe on Windows. macOS support depends on Apple's safaridriver.

This crate is intentionally tiny and is the only crate in the workspace that does not re-export anything from tauri; it's a separate binary with its own Cargo.toml and no library API.

Directory layout

crates/tauri-driver/
├── Cargo.toml
└── src/
    └── (CLI entry points and protocol routing)

How it works

graph LR
    Test["WebDriver client (selenium/wdio)"] -->|"WebDriver JSON"| TauriDriver["tauri-driver"]
    TauriDriver -->|"spawn + proxy"| Native["WebKitWebDriver / msedgedriver"]
    Native -->|"controls webview"| App["Tauri app"]

When the test harness asks the driver to open the app, tauri-driver spawns the user's binary with the right environment to attach the platform driver, then forwards subsequent commands.

Integration points

  • Up: invoked by external test harnesses; commonly wired up in tauri-action CI workflows.
  • Down: spawns WebKitWebDriver / msedgedriver.exe. Does not depend on the rest of the Tauri workspace at runtime — it is a standalone binary that happens to live in this repo.

Entry points for modification

  • Adjusting host resolution / port allocation: top of the crate's binary entry.
  • Adding support for a new platform (e.g. wiring up safaridriver more cleanly): the platform dispatch in the binary.

For practical end-to-end testing setup see the WebDriver guide on https://v2.tauri.app/develop/test/webdriver/.

Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.

tauri-driver – Tauri wiki | Factory