From ce1c510de7dbcfd49ade786a3516882d44abeca6 Mon Sep 17 00:00:00 2001 From: Tao Zhu Date: Wed, 15 Mar 2023 20:03:51 +0000 Subject: [PATCH] update tests --- rpc/src/rpc.rs | 10 +++++----- runtime/src/bank/tests.rs | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/rpc/src/rpc.rs b/rpc/src/rpc.rs index a90137f7e640be..dfd4d51cc1e642 100644 --- a/rpc/src/rpc.rs +++ b/rpc/src/rpc.rs @@ -5883,7 +5883,7 @@ pub mod tests { "Program 11111111111111111111111111111111 success" ], "returnData":null, - "unitsConsumed":0 + "unitsConsumed":150, } }, "id": 1, @@ -5967,7 +5967,7 @@ pub mod tests { "Program 11111111111111111111111111111111 success" ], "returnData":null, - "unitsConsumed":0 + "unitsConsumed":150, } }, "id": 1, @@ -5995,7 +5995,7 @@ pub mod tests { "Program 11111111111111111111111111111111 success" ], "returnData":null, - "unitsConsumed":0 + "unitsConsumed":150, } }, "id": 1, @@ -6044,7 +6044,7 @@ pub mod tests { "accounts":null, "logs":[], "returnData":null, - "unitsConsumed":0 + "unitsConsumed":0, } }, "id":1 @@ -6073,7 +6073,7 @@ pub mod tests { "Program 11111111111111111111111111111111 success" ], "returnData":null, - "unitsConsumed":0 + "unitsConsumed":150, } }, "id": 1, diff --git a/runtime/src/bank/tests.rs b/runtime/src/bank/tests.rs index d2f5b2d23a60b8..de7d0d85415ae0 100644 --- a/runtime/src/bank/tests.rs +++ b/runtime/src/bank/tests.rs @@ -10430,7 +10430,7 @@ fn test_compute_budget_program_noop() { assert_eq!( *compute_budget, ComputeBudget { - compute_unit_limit: 1, + compute_unit_limit: compute_budget::DEFAULT_INSTRUCTION_COMPUTE_UNIT_LIMIT as u64, heap_size: Some(48 * 1024), ..ComputeBudget::default() } @@ -10442,7 +10442,7 @@ fn test_compute_budget_program_noop() { let message = Message::new( &[ - ComputeBudgetInstruction::set_compute_unit_limit(1), + ComputeBudgetInstruction::set_compute_unit_limit(compute_budget::DEFAULT_INSTRUCTION_COMPUTE_UNIT_LIMIT), ComputeBudgetInstruction::request_heap_frame(48 * 1024), Instruction::new_with_bincode(program_id, &0, vec![]), ], @@ -10473,7 +10473,7 @@ fn test_compute_request_instruction() { assert_eq!( *compute_budget, ComputeBudget { - compute_unit_limit: 1, + compute_unit_limit: compute_budget::DEFAULT_INSTRUCTION_COMPUTE_UNIT_LIMIT as u64, heap_size: Some(48 * 1024), ..ComputeBudget::default() } @@ -10485,7 +10485,7 @@ fn test_compute_request_instruction() { let message = Message::new( &[ - ComputeBudgetInstruction::set_compute_unit_limit(1), + ComputeBudgetInstruction::set_compute_unit_limit(compute_budget::DEFAULT_INSTRUCTION_COMPUTE_UNIT_LIMIT), ComputeBudgetInstruction::request_heap_frame(48 * 1024), Instruction::new_with_bincode(program_id, &0, vec![]), ],