Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
kpinter-iohk committed Dec 13, 2024
1 parent 6a9d4b0 commit 686e84e
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions toolkit/partner-chains-cli/src/register/register3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ mod tests {
None,
PcContractsCliResources::default(),
)],
vec![MockIO::file_read("/path/to/payment.skey")],
run_registration_io(),
prompt_for_registration_status_y(),
show_registration_status_io(),
]
Expand All @@ -208,7 +208,7 @@ mod tests {
genesis_utxo(),
new_candidate_registration(),
payment_signing_key(),
Err(OffchainError::InternalError("".to_string())),
Err(OffchainError::InternalError("test error".to_string())),
);
let mock_context = MockIOContext::new()
.with_json_file("/path/to/payment.skey", payment_skey_content())
Expand All @@ -226,8 +226,7 @@ mod tests {
None,
PcContractsCliResources::default(),
)],
vec![MockIO::file_read("/path/to/payment.skey")],
// run_registration_command_fail_io(),
run_registration_fail_io(),
]
.into_iter()
.flatten()
Expand Down Expand Up @@ -262,7 +261,7 @@ mod tests {
None,
PcContractsCliResources::default(),
)],
vec![MockIO::file_read("/path/to/payment.skey")],
run_registration_io(),
prompt_for_registration_status_n(),
]
.into_iter()
Expand Down Expand Up @@ -327,6 +326,14 @@ mod tests {
]
}

fn run_registration_io() -> Vec<MockIO> {
vec![MockIO::file_read("/path/to/payment.skey")]
}

fn run_registration_fail_io() -> Vec<MockIO> {
vec![MockIO::file_read("/path/to/payment.skey")]
}

fn mock_register3_cmd() -> Register3Cmd {
Register3Cmd {
genesis_utxo: genesis_utxo(),
Expand Down

0 comments on commit 686e84e

Please sign in to comment.