Implement Reserve Contract and Stabilize Sweep Controller Tests#31
Implement Reserve Contract and Stabilize Sweep Controller Tests#31Emrys02 wants to merge 0 commit intobridgelet-org:mainfrom
Conversation
phertyameen
left a comment
There was a problem hiding this comment.
This PR is solving two separate issues at once.
- The reserve_contract storage implementation (set_base_reserve, get_base_reserve, tests) → (assigned to you)
- The sweep_controller import fix, env.register modernization, and workspace cleanup → belongs to issue #25 (pending assignment)
The work itself looks correct and valid, as it stands, issue #25 would remain open even though this PR resolves it, which creates confusion for the team.
Please create another pr or branch and touch only the intended files.
Also, remove all auto generated testSnapshots. Or better add it to gitignore. 3-5 files are much easier and faster to review.
| env.mock_all_auths(); | ||
|
|
||
| let contract_id = env.register_contract(None, EphemeralAccountContract); | ||
| let contract_id = env.register(EphemeralAccountContract, ()); |
There was a problem hiding this comment.
Why did you change this format?
There was a problem hiding this comment.
Why did you delete this profile.release?
|
@Emrys02 Please update your forked branch and make a pull locally before pushing. Important tests were changed! |
|
ok |
@phertyameen , sorry for the late response, i am just seeing this now. Yeah when i ran cargo test, i got errors, i had to fix it so i can also test the work i did. |
|
@phertyameen i will update it now |
|
Hey @Emrys02! 👋 It looks like this PR isn't linked to any issue. If this PR is for one of the issues assigned to you as part of a Wave, please link it to ensure your contribution is tracked properly. You can do this by adding a keyword to the PR description (e.g.,
|
Summary
This PR introduces the
reserve_contractfor managing base reserves and resolves critical build and test issues within thesweep_controller.Changes
Reserve Contract
reserve_contractto manage persistent base reserve storage with admin-only controls.initialize,set_base_reserve, andget_base_reserve.Sweep Controller Fixes
contractimport!macros with direct crate dependencies onephemeral_account.HostError 11) by ensuring Soroban objects are created within the correct test environment (Env).Workspace Cleanup
[profile.release]from individual sub-crates to the rootCargo.tomlto eliminate workspace warnings.env.register_contractcalls to the modernenv.registermethod.EphemeralAccountContract) and addressed all remaining compiler warnings for a crystal-clear build.Checklist
reserve_contractimplemented with admin-only persistent storageinitialize,set_base_reserve,get_base_reservecontractimport!macros replaced with direct crate dependenciesHostError 11resolved in integration tests[profile.release]centralized to rootCargo.tomlenv.register_contractcalls modernized toenv.registerVerification
closes 26