@@ -15050,7 +15050,7 @@ fn contract_limit_percentage_mempool_strategy_low_limit() {
15050
15050
15051
15051
#[test]
15052
15052
#[ignore]
15053
- /// Verify the block timestamp using `block-time`.
15053
+ /// Verify the block timestamp using `stacks- block-time`.
15054
15054
fn check_block_time_keyword() {
15055
15055
if env::var("BITCOIND_TEST") != Ok("1".into()) {
15056
15056
return;
@@ -15157,25 +15157,25 @@ fn check_block_time_keyword() {
15157
15157
let mut sender_nonce = 0;
15158
15158
let contract_name = "test-contract";
15159
15159
let contract = r#"
15160
- (define-constant deploy-time block-time)
15160
+ (define-constant deploy-time stacks- block-time)
15161
15161
(define-constant deploy-height stacks-block-height)
15162
15162
(define-read-only (get-current-time)
15163
- block-time
15163
+ stacks- block-time
15164
15164
)
15165
15165
(define-read-only (get-ihh (height uint)) (get-stacks-block-info? id-header-hash height))
15166
15166
(define-read-only (get-time (height uint)) (get-stacks-block-info? time height))
15167
15167
(define-read-only (get-height) stacks-block-height)
15168
15168
(define-read-only (get-previous-time (height uint))
15169
15169
(ok (at-block (unwrap! (get-stacks-block-info? id-header-hash height) (err u100))
15170
- block-time
15170
+ stacks- block-time
15171
15171
))
15172
15172
)
15173
15173
(define-public (get-current-time-call)
15174
- (ok block-time)
15174
+ (ok stacks- block-time)
15175
15175
)
15176
15176
(define-public (get-previous-time-call (height uint))
15177
15177
(ok (at-block (unwrap! (get-stacks-block-info? id-header-hash height) (err u100))
15178
- block-time
15178
+ stacks- block-time
15179
15179
))
15180
15180
)
15181
15181
"#;
@@ -15221,7 +15221,7 @@ fn check_block_time_keyword() {
15221
15221
let current_time = current_time_value.expect_u128().unwrap();
15222
15222
assert!(
15223
15223
current_time > deploy_time,
15224
- "block-time should be greater than the time at deployment"
15224
+ "stacks- block-time should be greater than the time at deployment"
15225
15225
);
15226
15226
15227
15227
let previous_time_result = call_read_only(
@@ -15292,13 +15292,16 @@ fn check_block_time_keyword() {
15292
15292
match contract_call.function_name.as_str() {
15293
15293
"get-current-time-call" => {
15294
15294
info!("Current time: {}", time);
15295
- assert!(time > current_time, "block-time should have advanced");
15295
+ assert!(
15296
+ time > current_time,
15297
+ "stacks-block-time should have advanced"
15298
+ );
15296
15299
}
15297
15300
"get-previous-time-call" => {
15298
15301
info!("Previous time: {}", time);
15299
15302
assert_eq!(
15300
15303
time, deploy_time,
15301
- "block-time should be the same as at deployment"
15304
+ "stacks- block-time should be the same as at deployment"
15302
15305
);
15303
15306
}
15304
15307
_ => panic!("Unexpected contract call"),
0 commit comments