pub fn operator_assignments(node_configs: &[NodeConfig]) -> Vec<OperatorRegistration> {
    node_configs
        .iter()
        .map(|n| {
            let test_config = n.test.as_ref().unwrap();
            let owner_key = test_config.owner_keypair.as_ref().unwrap().public_key();
            let operator_key = test_config.operator_keypair.as_ref().unwrap().public_key();
            let operator_account = account_address::from_public_key(&operator_key);
            let set_operator_script =
                transaction_builder::encode_set_validator_operator_script(operator_account);

            (owner_key, set_operator_script)
        })
        .collect::<Vec<_>>()
}
/// Generates an artificial set of OperatorAssignments using the given node configurations for
/// testing.
Generates an artificial set of OperatorAssignments using the given node configurations for
testing.
Generates an artificial set of OperatorAssignments using the given node configurations for testing .
pub fn operator_assignments(node_configs: &[NodeConfig]) -> Vec<OperatorRegistration> {
    node_configs
        .iter()
        .map(|n| {
            let test_config = n.test.as_ref().unwrap();
            let owner_key = test_config.owner_keypair.as_ref().unwrap().public_key();
            let operator_key = test_config.operator_keypair.as_ref().unwrap().public_key();
            let operator_account = account_address::from_public_key(&operator_key);
            let set_operator_script =
                transaction_builder::encode_set_validator_operator_script(operator_account);
            (owner_key, set_operator_script)
        })
        .collect::<Vec<_>>()
}
pub fn operator_assignments ( node_configs : & [ NodeConfig ] ) -> Vec < OperatorRegistration > { node_configs . iter ( ) . map ( | n | { let test_config = n . test . as_ref ( ) . unwrap ( ) ; let owner_key = test_config . owner_keypair . as_ref ( ) . unwrap ( ) . public_key ( ) ; let operator_key = test_config . operator_keypair . as_ref ( ) . unwrap ( ) . public_key ( ) ; let operator_account = account_address :: from_public_key ( & operator_key ) ; let set_operator_script = transaction_builder :: encode_set_validator_operator_script ( operator_account ) ; ( owner_key , set_operator_script ) } ) . collect :: < Vec < _ > > ( ) }
Generates an artificial set of OperatorAssignments using the given node configurations for
testing.
Generates an artificial set of OperatorAssignments using the given node configurations for testing .
node_configs
&[NodeConfig]
node_configs
&[NodeConfig]