OpenViSTAI · Agents · Blockchain · Crypto
Menu
Developer Tools

Solana Bankrun

Solana Bankrun is a Node.js framework for testing Solana programs in a lightweight local BanksServer environment. Tests interact with that server through a BanksClient, with documented support for transactions, dynamic account-data changes and moving bank state backward or forward in time. The repository marks Bankrun deprecated and recommends LiteSVM.

Independent OpenViST project profile, based on linked sources.

Solana Bankrun — OpenViST project profile in Developer Tools.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use the documentation to understand or maintain a Bankrun-based local testing setup. For a new framework choice, account for the repository’s deprecation notice and its recommendation to use LiteSVM.

Who it is for

  • Developers writing Node.js tests for Solana programs
  • Teams testing transaction outcomes, account data or time-dependent behavior in a local bank environment

Documented uses

  • Submit transactions through a BanksClient and inspect outcomes such as account balances.
  • Set account data dynamically as part of a test.
  • Move bank state backward or forward to test time-dependent behavior.
Before you choose

Requirements & limits

The repository specifies the Apache-2.0 license. Its installation example uses Yarn.

  • Bankrun uses a lightweight BanksServer with a BanksClient rather than describing a remote RPC testing workflow.
  • The project is deprecated; the repository recommends LiteSVM, but provides no migration steps or compatibility guarantee in the cited material.
  • The README warns that concurrent Jest test files can occasionally fail and suggests running them with --runInBand.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Set up the documented Bankrun test example

Install Bankrun and prepare a Node.js test that submits a transfer and checks the resulting balance.

Before you start

  • A Node.js project
  • Yarn
  • The solana-bankrun package
  • The @solana/web3.js package
  • A test runner such as Jest; the README says other test runners can be used

Steps

  1. Add Bankrun to the project with yarn add solana-bankrun.

  2. Import start from solana-bankrun and the transaction and system-program types from @solana/web3.js in a test file.

  3. Start a context with start([], []), then use its BanksClient, payer and last blockhash to construct and submit the documented lamport transfer.

  4. Read the receiver’s balance through the BanksClient and assert that it equals the transferred amount.

Expected outcome

A test structured like the README example, checking a transaction’s resulting receiver balance in Bankrun’s local bank environment.

Guide limitations

  • The repository marks Bankrun deprecated and recommends LiteSVM instead.
  • The README notes occasional failures with concurrent Jest test files and suggests --runInBand.
  • This setup recipe does not demonstrate loading or testing a user-provided Solana program.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
14 October 2026
Original website title
kevinheavey/solana-bankrun · Official homepage title · retained in its source language

Related options

LiteSVM — The Bankrun repository’s recommended successor for Solana program testing. The cited material does not document migration steps or verify compatibility.

Explore project →