Transaction format changes toward Credit-Only accounts (#4386)
* Add num_readonly_accounts slice * Impl programs in account_keys * Emulate current account-loading functionality using program-account_keys (breaks exchange_program_api tests) * Fix test * Add temporary exchange faucet id * Update chacha golden * Split num_credit_only_accounts into separate fields * Improve readability * Move message field constants into Message * Add MessageHeader struct and fixup comments
This commit is contained in:
@@ -11,3 +11,22 @@ pub const EXCHANGE_PROGRAM_ID: [u8; 32] = [
|
||||
];
|
||||
|
||||
solana_sdk::solana_program_id!(EXCHANGE_PROGRAM_ID);
|
||||
|
||||
pub const EXCHANGE_FAUCET_ID: [u8; 32] = [
|
||||
3, 147, 111, 103, 210, 47, 23, 11, 176, 29, 147, 89, 237, 155, 21, 62, 107, 105, 157, 1, 98,
|
||||
204, 206, 211, 54, 212, 79, 15, 160, 0, 0, 0,
|
||||
];
|
||||
|
||||
pub fn faucet_id() -> solana_sdk::pubkey::Pubkey {
|
||||
solana_sdk::pubkey::Pubkey::new(&EXCHANGE_FAUCET_ID)
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
#[test]
|
||||
fn exchange_faucet_id() {
|
||||
let ids = [("ExchangeFaucet11111111111111111111111111111", faucet_id())];
|
||||
assert!(ids.iter().all(|(name, id)| *name == id.to_string()));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user