@@ -9,7 +9,7 @@ use std::str::FromStr;
9
9
const BLOCK_4_TS_MILLIS : u64 = 1650561570000 ;
10
10
const BLOCK_5_TS_MILLIS : u64 = 1650562570000 ;
11
11
12
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
12
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
13
13
async fn get_latest_block_info ( pool : PgPool ) {
14
14
let irrelevant_security_parameter = 1000 ;
15
15
let source = mk_datasource ( pool, irrelevant_security_parameter) ;
@@ -29,7 +29,7 @@ async fn get_latest_block_info(pool: PgPool) {
29
29
assert_eq ! ( block, expected)
30
30
}
31
31
32
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
32
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
33
33
async fn test_get_latest_stable_block ( pool : PgPool ) {
34
34
let security_parameter = 2 ;
35
35
let source = mk_datasource ( pool, security_parameter) ;
@@ -43,7 +43,7 @@ async fn test_get_latest_stable_block(pool: PgPool) {
43
43
assert_eq ! ( block, Some ( expected) )
44
44
}
45
45
46
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
46
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
47
47
async fn test_get_latest_stable_block_at_filters_out_by_max_slot_boundary ( pool : PgPool ) {
48
48
let security_parameter = 2 ;
49
49
let slots_distance_between_blocks = block_4 ( ) . slot . 0 - block_2 ( ) . slot . 0 ;
@@ -58,7 +58,7 @@ async fn test_get_latest_stable_block_at_filters_out_by_max_slot_boundary(pool:
58
58
assert_eq ! ( block, None )
59
59
}
60
60
61
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
61
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
62
62
async fn test_get_stable_block_at ( pool : PgPool ) {
63
63
let security_parameter = 2 ;
64
64
let source = mk_datasource ( pool, security_parameter) ;
@@ -70,7 +70,7 @@ async fn test_get_stable_block_at(pool: PgPool) {
70
70
assert_eq ! ( block, Some ( block_2( ) ) ) ;
71
71
}
72
72
73
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
73
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
74
74
async fn test_get_stable_block_at_returns_block_that_dont_have_k_blocks_on_them_at_given_timestamp (
75
75
pool : PgPool ,
76
76
) {
@@ -85,7 +85,7 @@ async fn test_get_stable_block_at_returns_block_that_dont_have_k_blocks_on_them_
85
85
assert_eq ! ( block, Some ( block_2( ) ) ) ;
86
86
}
87
87
88
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
88
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
89
89
async fn test_get_stable_block_at_filters_out_by_min_slots_boundary ( pool : PgPool ) {
90
90
let security_parameter = 3 ;
91
91
let slots_distance_between_blocks = block_4 ( ) . slot . 0 - block_2 ( ) . slot . 0 ;
@@ -104,7 +104,7 @@ async fn test_get_stable_block_at_filters_out_by_min_slots_boundary(pool: PgPool
104
104
assert_eq ! ( block, None ) ;
105
105
}
106
106
107
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
107
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
108
108
async fn test_get_stable_block_at_filters_out_by_max_slots_boundary ( pool : PgPool ) {
109
109
let security_parameter = 2 ;
110
110
let slots_distance_between_blocks = block_4 ( ) . slot . 0 - block_2 ( ) . slot . 0 ;
@@ -123,7 +123,7 @@ async fn test_get_stable_block_at_filters_out_by_max_slots_boundary(pool: PgPool
123
123
assert_eq ! ( block, None ) ;
124
124
}
125
125
126
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
126
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
127
127
async fn test_get_stable_block_info_by_hash_for_unknown_hash ( pool : PgPool ) {
128
128
let source = mk_datasource ( pool, 2 ) ;
129
129
let unknown_hash =
@@ -135,7 +135,7 @@ async fn test_get_stable_block_info_by_hash_for_unknown_hash(pool: PgPool) {
135
135
assert_eq ! ( result, None )
136
136
}
137
137
138
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
138
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
139
139
async fn test_get_latest_stable_block_with_stability_margin ( pool : PgPool ) {
140
140
let security_parameter = 2 ;
141
141
let stability_margin = 1 ;
@@ -164,7 +164,7 @@ async fn test_get_latest_stable_block_with_stability_margin(pool: PgPool) {
164
164
assert_eq ! ( block, None ) ;
165
165
}
166
166
167
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
167
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
168
168
async fn test_get_latest_stable_block_with_stability_margin_2 ( pool : PgPool ) {
169
169
let security_parameter = 2 ;
170
170
let stability_margin = 0 ;
@@ -190,7 +190,7 @@ async fn test_get_latest_stable_block_with_stability_margin_2(pool: PgPool) {
190
190
assert_eq ! ( block, Some ( block_0( ) ) ) ;
191
191
}
192
192
193
- #[ sqlx:: test( migrations = "./testdata/migrations" ) ]
193
+ #[ sqlx:: test( migrations = "./testdata/migrations-v2 " ) ]
194
194
async fn test_get_stable_block_caching ( pool : PgPool ) {
195
195
fn dummy_hash ( n : u8 ) -> McBlockHash {
196
196
McBlockHash ( [ n; 32 ] )
0 commit comments