1#![cfg_attr(feature = "bench-suite", feature(test))]
4
5extern crate chrono;
6
7#[cfg(any(feature = "bench-suite", feature = "test-suite"))]
8#[macro_use]
9extern crate indradb;
10#[cfg(not(any(feature = "bench-suite", feature = "test-suite")))]
11extern crate indradb;
12
13extern crate serde_json;
14extern crate sled;
15#[cfg(any(feature = "bench-suite", feature = "test-suite"))]
16extern crate tempfile;
17extern crate uuid;
18
19mod datastore;
20mod errors;
21mod managers;
22
23pub use self::datastore::{SledConfig, SledDatastore, SledTransaction};
24
25mod normal_config {
26 #[cfg(feature = "bench-suite")]
27 full_bench_impl!({
28 use super::SledDatastore;
29 use tempfile::tempdir;
30 let path = tempdir().unwrap().into_path();
31 SledDatastore::new(path).unwrap()
32 });
33
34 #[cfg(feature = "test-suite")]
35 full_test_impl!({
36 use super::SledDatastore;
37 use tempfile::tempdir;
38 let path = tempdir().unwrap().into_path();
39 SledDatastore::new(path).unwrap()
40 });
41}
42
43mod compression_config {
44 #[cfg(feature = "bench-suite")]
45 full_bench_impl!({
46 use super::SledConfig;
47 use tempfile::tempdir;
48 let path = tempdir().unwrap().into_path();
49 SledConfig::with_compression(None).open(path).unwrap()
50 });
51
52 #[cfg(feature = "test-suite")]
53 full_test_impl!({
54 use super::SledConfig;
55 use tempfile::tempdir;
56 let path = tempdir().unwrap().into_path();
57 SledConfig::with_compression(None).open(path).unwrap()
58 });
59}