Problem Statement Today each test creates its own Env::default(). This is correct but slow; some tests share storage prefix patterns and could overlap. There is no documented contract for test parallelization.
Expected Outcome Add a fixture pattern with with_campaign(prefix: &str) that sets env, registers the contract, and yields a builder the caller can use for setup. Optionally introduce per-test prefixes to allow some parallel runs if future Soroban tooling supports it.
Acceptance Criteria
- New helper in
campaign/src/test/mod.rs.
- Existing tests can opt in (optional).
- The fixture documents wait-for-
mock_all_auths and ordering guidance.
Implementation Notes
- Keep simple; do not force a rewrite of all tests.
Affected Files / Modules
Dependencies — None.
Problem Statement Today each test creates its own
Env::default(). This is correct but slow; some tests share storage prefix patterns and could overlap. There is no documented contract for test parallelization.Expected Outcome Add a fixture pattern with
with_campaign(prefix: &str)that sets env, registers the contract, and yields a builder the caller can use for setup. Optionally introduce per-test prefixes to allow some parallel runs if future Soroban tooling supports it.Acceptance Criteria
campaign/src/test/mod.rs.mock_all_authsand ordering guidance.Implementation Notes
Affected Files / Modules
campaign/src/test/mod.rsDependencies — None.