Creates a test database with a 100 MB map size (vs reth's default 8 TB).
()
| 143 | |
| 144 | /// Creates a test database with a 100 MB map size (vs reth's default 8 TB). |
| 145 | fn create_test_database() -> Result<(DatabaseEnv, PathBuf)> { |
| 146 | let path = tempdir_path(); |
| 147 | let args = DatabaseArguments::new(ClientVersion::default()) |
| 148 | .with_geometry_max_size(Some(100 * 1024 * 1024)); |
| 149 | let db = init_db(&path, args).expect("Failed to create test database"); |
| 150 | Ok((db, path)) |
| 151 | } |
| 152 | |
| 153 | /// Create an HTTP provider pointed at the node's public RPC endpoint. |
| 154 | pub fn provider(&self) -> Result<RootProvider<Base>> { |