@@ -15,7 +15,10 @@ mod test {
1515 } ;
1616 use alloy:: primitives:: { B256 , Bytes , U256 , address, b256} ;
1717 use reth:: primitives:: { Account , Bytecode , Header , SealedHeader } ;
18- use reth_db:: BlockNumberList ;
18+ use reth_db:: {
19+ BlockNumberList , ClientVersion , mdbx:: DatabaseArguments , test_utils:: tempdir_path,
20+ } ;
21+ use reth_libmdbx:: MaxReadTransactionDuration ;
1922
2023 #[ test]
2124 fn mem_conformance ( ) {
@@ -25,10 +28,16 @@ mod test {
2528
2629 #[ test]
2730 fn mdbx_conformance ( ) {
28- let db = reth_db:: test_utils:: create_test_rw_db ( ) ;
31+ let path = tempdir_path ( ) ;
32+ let db = reth_db:: create_db (
33+ & path,
34+ DatabaseArguments :: new ( ClientVersion :: default ( ) )
35+ . with_max_read_transaction_duration ( Some ( MaxReadTransactionDuration :: Unbounded ) ) ,
36+ )
37+ . unwrap ( ) ;
2938
3039 // Create tables from the `crate::tables::hot` module
31- let mut writer = db. db ( ) . writer ( ) . unwrap ( ) ;
40+ let mut writer = db. writer ( ) . unwrap ( ) ;
3241
3342 writer. queue_create :: < hot:: Headers > ( ) . unwrap ( ) ;
3443 writer. queue_create :: < hot:: HeaderNumbers > ( ) . unwrap ( ) ;
@@ -42,7 +51,7 @@ mod test {
4251
4352 writer. commit ( ) . expect ( "Failed to commit table creation" ) ;
4453
45- conformance ( db . db ( ) ) ;
54+ conformance ( & db ) ;
4655 }
4756
4857 fn conformance < T : HotKv > ( hot_kv : & T ) {
@@ -235,7 +244,9 @@ mod test {
235244 // Read account change
236245 {
237246 let reader = hot_kv. reader ( ) . unwrap ( ) ;
247+
238248 let read_change = reader. get_account_change ( block_number, & addr) . unwrap ( ) ;
249+
239250 assert ! ( read_change. is_some( ) ) ;
240251 let change = read_change. unwrap ( ) ;
241252 assert_eq ! ( change. nonce, 10 ) ;
0 commit comments