1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
//! Test-only builders for a REAL terminal singleton melt — the spend a profile deletion is made of.
//!
//! A melt is the one authorizable act whose entire effect is destruction: it creates no coin, so it
//! is invisible in a summary's recipient lines and shows up in the fee only as the singleton's lone
//! mojo. Every property this crate asserts about a melt therefore has to be asserted over a spend
//! that really melts something, and a hand-rolled approximation of one would prove nothing: the
//! `MELT_SINGLETON` marker must sit inside the SIGNED delegated puzzle of a genuine singleton spend
//! before `dig-wallet-backend`'s verify gate will account it as a melt at all.
//!
//! So the bundles here come from `dig-merkle`'s own canonical mint + melt builders, exactly as a
//! profile deletion would build them. Nothing in this module is reachable outside `cfg(test)`.
use PublicKey;
use ;
/// A real dig-store singleton, launched from `parent_seed` and then MELTED, owned by `owner_key`.
///
/// Returns the melt's coin spends. Passing the wallet's own money key as `owner_key` produces a
/// singleton the wallet can actually sign the destruction of — the owned-melt case, which is what a
/// user deleting their own profile performs.
///
/// `parent_seed` distinguishes one launch from another: two calls with different seeds melt two
/// DIFFERENT singletons, which is what a profile deletion (a DID plus a dig-store) does and what a
/// multiset comparison of destroyed lineages needs in order to be more than a one-element check.
pub
/// The coin id of the singleton `store_melt_owned_by` destroys, as the lowercase hex a summary
/// names it by.
///
/// Read off the melt's own coin spend rather than recomputed, so a test comparing a summary against
/// it is comparing the summary to the bundle rather than to a second derivation that could drift
/// with it.
pub