(client: &Client, id: u64, size: usize)
| 35 | } |
| 36 | |
| 37 | pub fn update(client: &Client, id: u64, size: usize) -> Result<(), CliError> { |
| 38 | let pool_pubkey = Pool::pubkey(id); |
| 39 | let settings = PoolSettings { size }; |
| 40 | let ix = Instruction { |
| 41 | program_id: clockwork_network_program::ID, |
| 42 | accounts: clockwork_network_program::accounts::PoolUpdate { |
| 43 | admin: client.payer_pubkey(), |
| 44 | config: Config::pubkey(), |
| 45 | payer: client.payer_pubkey(), |
| 46 | pool: pool_pubkey, |
| 47 | system_program: system_program::ID, |
| 48 | }.to_account_metas(Some(false)), |
| 49 | data: clockwork_network_program::instruction::PoolUpdate { settings }.data(), |
| 50 | }; |
| 51 | client.send_and_confirm(&[ix], &[client.payer()]).unwrap(); |
| 52 | get(client, id)?; |
| 53 | Ok(()) |
| 54 | } |
no test coverage detected