-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add support for --sbf-program
flag in test-validator
#1393
Conversation
This allows adding SBF programs to the genesis configuration with upgrades disabled. The flag accepts pairs of arguments (address and path) to specify programs, and validates input to ensure correct usage.
Thanks for the pr! can you add tests? additionally can you adapt the template we use in Does this work with multiple programs as inputs like this? |
Can you add a check for duplicates and collisions with our system programs? |
…am checks + add tests
Done (and while adding tests found a bug with the
Hm, the only place where we load sbf programs in template is https://github.com/Lightprotocol/compressed-program-template/blob/main/programs/%7B%7Brust-name%7D%7D/tests/test.rs#L27, but it's solana runtime, unrelated to our typescript cli, am I missed something?
Yes. |
Wrt template, you are right the template doesn't have a typescript right now. I thought it would be nice to have the correct command to run the test command with a correctly configured light cli already even though its not used yet. But we can add this as well once we have added a ts test to the template. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding the tests!
Looks great! Just have one more assert I would like to see.
… test-validator command * added test check to validate the program deployment and ensure the account is executable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm feel free to merge once green!
This allows adding SBF programs to the genesis configuration with upgrades disabled. The flag accepts pairs of arguments (address and path) to specify programs, and validates input to ensure correct usage.