| Crates.io | bulloak-foundry |
| lib.rs | bulloak-foundry |
| version | 0.9.0 |
| created_at | 2024-07-27 09:08:37.974039+00 |
| updated_at | 2025-09-17 19:02:00.140541+00 |
| description | A Solidity test generator based on the Branching Tree Technique. |
| homepage | https://github.com/alexfertel/bulloak |
| repository | https://github.com/alexfertel/bulloak |
| max_upload_size | |
| id | 1317125 |
| size | 275,643 |
bulloak-foundry is a Rust crate that serves as a backend for generating
Foundry tests from bulloak-syntax Abstract Syntax Trees (ASTs). It provides
functionality to scaffold Solidity test files and check existing tests against
specifications.
.t.sol files with scaffolded Foundry tests from bulloak-syntax
ASTs..tree specifications.bulloak
prepends nearest ancestor conditions (and if needed multiple ancestors) to
produce a unique name.To use bulloak-foundry in your project, add it to your Cargo.toml:
[dependencies]
bulloak-foundry = "0.1.0" # Replace with the actual version
use bulloak_foundry::{config::Config, scaffold};
fn main() -> anyhow::Result<()> {
let tree_spec = "Your .tree specification here";
let cfg = Config::default(); // customize as needed
let foundry_test = scaffold::scaffold(tree_spec, &cfg)?;
// Write foundry_test to a .t.sol file
Ok(())
}
bulloak-foundry includes a system for defining and checking rules against
Solidity test files. Violations can be of different kinds, as defined in the
ViolationKind enum.
This project is licensed under either of: