Remove fee-payer guesswork from Message and Transaction (#10776)

* Make Message::new_with_payer the default constructor

* Remove Transaction::new_[un]signed_instructions

These guess the fee-payer instead of stating it explicitly
This commit is contained in:
Greg Fitzgerald
2020-06-24 14:52:38 -06:00
committed by GitHub
parent d5d5ad0071
commit 1c498369b5
47 changed files with 516 additions and 497 deletions

View File

@@ -93,7 +93,7 @@ mod tests {
owner_pubkey,
lamports,
);
let message = Message::new(&instructions);
let message = Message::new(&instructions, Some(&payer_keypair.pubkey()));
bank_client.send_message(&[payer_keypair, account_keypair], message)
}
@@ -109,7 +109,7 @@ mod tests {
&old_owner_keypair.pubkey(),
new_owner_pubkey,
);
let message = Message::new_with_payer(&[instruction], Some(&payer_keypair.pubkey()));
let message = Message::new(&[instruction], Some(&payer_keypair.pubkey()));
bank_client.send_message(&[payer_keypair, old_owner_keypair], message)
}