Labels: Stellar Wave, stellar, test, drips, help-wanted
Tier: M (2–4 days)
Type: test
Context
Today every Stellar contract has unit tests, but no property-based / fuzz coverage. Stealth address payments are arithmetic-heavy and have many edge cases (empty payloads, oversized data, malformed addresses) — exactly the kind of thing where property tests pay off.
This issue adds a proptest-based test layer that lives alongside the existing unit tests.
Scope
Add proptest (or quickcheck if preferred — pick one and justify) as a dev-dependency in each of the four Stellar crates:
stealth-announcer
stealth-registry
stealth-sender
wraith-names
For each contract, write at least 5 properties that should always hold:
Examples
- announcer: For any
(scheme_id, stealth_address, ephemeral_pub_key, metadata) where lengths are valid, announce() emits exactly one event with those fields verbatim.
- registry:
register_keys then stealth_meta_address_of for the same (registrant, scheme_id) round-trips bit-for-bit.
- sender:
batch_send of N transfers either fully succeeds (announcement count == N) or fully fails (announcement count == 0). Never partial.
- wraith-names: Any 3–32-char lowercase alphanumeric name registered, then
resolve()'d, returns the exact meta-address passed in. Any name outside that grammar panics.
Coverage requirement
Run with proptest! cases ≥ 1024 by default; ≥ 16384 in CI nightly job. Report any flaky tests; we'd rather find non-determinism now than in production.
Acceptance criteria
Resources
Labels:
Stellar Wave,stellar,test,drips,help-wantedTier: M (2–4 days)
Type: test
Context
Today every Stellar contract has unit tests, but no property-based / fuzz coverage. Stealth address payments are arithmetic-heavy and have many edge cases (empty payloads, oversized data, malformed addresses) — exactly the kind of thing where property tests pay off.
This issue adds a
proptest-based test layer that lives alongside the existing unit tests.Scope
Add
proptest(orquickcheckif preferred — pick one and justify) as a dev-dependency in each of the four Stellar crates:stealth-announcerstealth-registrystealth-senderwraith-namesFor each contract, write at least 5 properties that should always hold:
Examples
(scheme_id, stealth_address, ephemeral_pub_key, metadata)where lengths are valid,announce()emits exactly one event with those fields verbatim.register_keysthenstealth_meta_address_offor the same(registrant, scheme_id)round-trips bit-for-bit.batch_sendof N transfers either fully succeeds (announcement count == N) or fully fails (announcement count == 0). Never partial.resolve()'d, returns the exact meta-address passed in. Any name outside that grammar panics.Coverage requirement
Run with
proptest!cases ≥ 1024 by default; ≥ 16384 in CI nightly job. Report any flaky tests; we'd rather find non-determinism now than in production.Acceptance criteria
proptestdev-dependency added to all four Stellar crates.tests/properties.rsin each crate with at least 5 properties.nightlyjob that runs with the larger case count, alongside the existingtestjob.Resources
proptestbook: https://proptest-rs.github.io/proptest/soroban-sdktestutils: https://docs.rs/soroban-sdk/latest/soroban_sdk/testutils/