Rust <-> Solidity Unit Testing #8765
JayWhite2357
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
One thing that is particularly interesting for our project (and many others) is the ability to send data between Solidity and a Rust service.
Having the ability to unit test the combination of the two of these languages would be a powerful primitive. Here's what I have gotten to work for us.
It feels a bit hacky, and I'm sure there could be a much simpler integration done quite easily. One concrete request from my end is for
forge-script
to be published tocrates.io
in order for dependencies to resolve more easily, as this was, by far, the most difficult part.If anyone has suggestions on a better way of going about this, and if I'm missing something obvious here, I'm all ears. Perhaps revm+foundry-compilers is the correct way to do this, but I didn't see anything as immediately simple as forge-script.
TestScript.t.sol
sol_test.rs
Beta Was this translation helpful? Give feedback.
All reactions