Back to Sway

Sway + Rust test templates

templates/README.md

0.72.1803 B
Original Source

Sway + Rust test templates

This directory contains cargo generate templates for Rust integration tests:

TemplateSway program type
sway-test-rsContract
sway-script-test-rsScript
sway-predicate-test-rsPredicate

All three templates use the same Rust SDK minor as the fuels dependency in the repository root and the SDK harness exercised by Sway CI. CI checks this relationship so one program type cannot silently fall behind the others.

On master, the templates follow the default branch and may require unreleased Sway behavior. A template from a vX.Y.Z tag is the release-specific snapshot; generate from the tag that matches your Forc version rather than assuming the default branch is compatible. Confirm the compiler with forc --version.