Skip to content

[Phase 5] Soft-fork testing roadmap (tracking) #83

Description

@neverDefined

Goal

Make go-regtest a first-class test harness for Bitcoin soft-forks (APO/eltoo, CTV and LNHANCE, CSFS, and future deployments), so application developers can write deterministic integration tests against a patched bitcoind binary.

What lives where

  • Soft-fork rules live in the `bitcoind` binary (mainline Core, `bitcoin-inquisition` for APO, CTV fork, etc.). go-regtest is binary-agnostic.
  • go-regtest's job is the deterministic harness around that binary: start with the right flags, observe activation state, feed transactions, surface the exact reject reasons.

The five-phase test shape every soft-fork test follows

  1. Start the node with the deployment configured (`VBParams`, `AcceptNonstdTxn`).
  2. Verify activation — skip if the binary doesn't expose the deployment.
  3. Build the tx that exercises the new rule (your protocol code + `btcsuite/txscript`).
  4. Probe with `TestMempoolAccept` — accept/reject with the exact reason.
  5. Broadcast, mine, observe — optionally reorg to test sig rebinding (eltoo).

Milestones

Phase 5.0 — Foundation (eltoo-test-minimum)

Tier A — Foundation

Tier B — Activation ergonomics

Tier C — Consensus-rule exercising

Tier D — Reorg

Tier E — Acceptance

Phase 5.1 — Expansion

Tier B — Mining helpers

Tier C — Block & raw-tx wrappers

Tier D — Multi-node

Tier E — Tooling

Dependency graph (critical path for Phase 5.0)

```
#66 ExtraArgs ────┬──> #67 VBParams ─────┐
└──> #73 AcceptNonstdTxn ─┤

#69 GetDeploymentInfo ──> #72 DeploymentStatus ──┼──> #81 testdummy example

#74 TestMempoolAccept ──────────────────────┘
#77 Chain inspection ──> #78 Reorg primitives (independent of above)
#68 GetBlockChainInfo (independent)
```

The unblocking path to a runnable soft-fork test is #66#67#69#72#73#74#81. Everything else can land in any order.

Related

Out of scope for Phase 5 (candidates for Phase 5.2+)

  • `BitcoinCoreVersion()` + documented minimum supported Core (Core 24+ is the assumed minimum).
  • Additive `WarpBlocks(...) ([]chainhash.Hash, error)` that returns mined block hashes.
  • PSBT wrappers (`WalletProcessPSBT`, `FinalizePSBT`).

Open a separate issue if any of these become necessary before 5.2.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions