Enable WAL mode in expensive Merkle state test
This commit adds an version of the `merkle_trie_update` with WAL mode
activated.  Also, it renames the old test  to
`merkle_trie_update_atomic_commit_rollback`  These two tests can be
compared with the time command.
@@ -1371,7 +1371,7 @@ mod sqlitedb {
}
#[test]
- fn merkle_trie_update() {
+ fn merkle_trie_update_atomic_commit_rollback() {
run_test(|db_path| {
let db = Box::new(
SqliteDatabase::new(&db_path, &INDEXES).expect("Unable to create Sqlite database"),
@@ -1380,6 +1380,21 @@ mod sqlitedb {
})
}
+ #[test]
+ fn merkle_trie_update_with_wal_mode() {
+ run_test(|db_path| {
+ let db = Box::new(
+ SqliteDatabase::builder()
+ .with_path(db_path)
+ .with_indexes(&INDEXES)
+ .with_write_ahead_log_mode()
+ .build()
+ .expect("Unable to create Sqlite database"),
+ );
+ test_merkle_trie_update(db);
+ })
+ }
+
#[test]
fn merkle_trie_update_same_address_space() {
run_test(|db_path| {
