feat(wallet): mainnet pruned and full on-device chain modes
Cuprate in-process and TUI keys 1/2/3 pick mainnet pruned, mainnet full, or experimental testnet. Datadirs are split so a prune store cannot mix with a full one. Android storage floors scale with the choice. Cuprate remains pre-production; mainnet is unvalidated.
This commit is contained in:
parent
0acf89a0b4
commit
5080652e3b
11 changed files with 397 additions and 77 deletions
|
|
@ -1138,9 +1138,10 @@ fn chain_source_labels_name_what_the_child_dials() {
|
|||
ChainSource::Local {
|
||||
monerod_bin: PathBuf::from("/usr/bin/monerod"),
|
||||
datadir: PathBuf::from("/var/lib/onionwire"),
|
||||
prune: false,
|
||||
}
|
||||
.label(),
|
||||
"local node"
|
||||
"local full node"
|
||||
);
|
||||
assert_eq!(
|
||||
ChainSource::Remote {
|
||||
|
|
@ -1226,6 +1227,7 @@ fn child_settings_round_trip_sealed_and_keep_the_creds() {
|
|||
local.source = ChainSource::Local {
|
||||
monerod_bin: PathBuf::new(),
|
||||
datadir: PathBuf::from("/var/lib/onionwire"),
|
||||
prune: false,
|
||||
};
|
||||
let err = local.validate().expect_err("a local node needs monerod");
|
||||
assert!(err.to_string().contains("monerod path required"), "{err}");
|
||||
|
|
@ -1265,7 +1267,7 @@ async fn an_in_process_cuprate_node_answers_the_typed_daemon_client() {
|
|||
let addr = format!("127.0.0.1:{port}");
|
||||
let budget = std::time::Duration::from_secs(5);
|
||||
|
||||
let mut node = onionwire::cuprate::CuprateNode::launch(&datadir, port)
|
||||
let mut node = onionwire::cuprate::CuprateNode::launch(&datadir, port, "Testnet", false)
|
||||
.expect("launch the in-process testnet daemon");
|
||||
|
||||
// `launch` returns with the services started; the RPC listener can still be
|
||||
|
|
|
|||
Loading…
Reference in a new issue