Skip to content

Installation

Requirements

  • Node.js 18 or later (for running tests)
  • npm or yarn (for project dependencies)

Install from npm

The recommended way to install rjest for Node.js projects:

npm install -D rjest-install

Then use it just like Jest:

npx rjest
npx rjest --watch
npx rjest --coverage

Install from Homebrew

On macOS and Linux:

brew tap neul-labs/tap
brew install rjest

Install from crates.io

If you have the Rust toolchain installed:

cargo install rjest

This installs the jest (CLI shim) and jestd (background daemon) binaries into your Cargo bin directory (usually ~/.cargo/bin). The daemon is spawned automatically by the CLI; you should not need to run jestd directly.

Install from PyPI

For Python projects or environments where pip is preferred:

pip install rjest-install

This installs a Python wrapper that calls the Rust binary.

Install from Source

Build from source if you need the latest changes or want to contribute:

# Clone the repository
git clone https://github.com/neul-labs/rjest.git
cd rjest

# Build release binaries
cargo build --release

# The binaries are in target/release/
# - jest    (CLI)
# - jestd   (daemon)

Add to PATH

Add the binaries to your PATH for easy access:

# Option 1: Symlink to local bin
ln -s $(pwd)/target/release/jest ~/.local/bin/rjest
ln -s $(pwd)/target/release/jestd ~/.local/bin/rjestd

# Option 2: Add to PATH in your shell config
export PATH="$PATH:/path/to/rjest/target/release"

Verify Installation

# Check version
jest --version

# Run help
jest --help

Project Setup

rjest works with existing Jest projects. Ensure your project has:

1. A Jest Configuration

jest.config.js
module.exports = {
  testMatch: ['**/*.test.ts', '**/*.test.js'],
  moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
};

2. Required Dependencies

# TypeScript projects need these peer dependencies
npm install --save-dev typescript @types/jest

No Babel Required

Unlike Jest with ts-jest or @swc/jest, rjest has built-in TypeScript compilation using native SWC. You don't need to configure any transform.

Daemon Management

rjest runs a background daemon for fast subsequent runs:

# The daemon starts automatically on first run
jest

# Check daemon status
jest --daemon-status

# Stop the daemon (frees memory)
jest --daemon-stop

Next Steps