aboutsummaryrefslogtreecommitdiffstats
path: root/log_db/tests
diff options
context:
space:
mode:
authorJan Tuomi <jan@jantuomi.fi>2024-10-10 23:41:10 +0300
committerJan Tuomi <jan@jantuomi.fi>2024-10-10 23:41:10 +0300
commitee0a81cf0277a7ff8683f94cc95a23f29996d980 (patch)
tree263ae30f5057c402bf9d73ae6e26e08ad0ec22e8 /log_db/tests
parent336afff93bdd09cfaad75bde25d6d6627ef7c24f (diff)
Add invariant that memtables should always have the same set of primary key references
Diffstat (limited to 'log_db/tests')
-rw-r--r--log_db/tests/integration.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/log_db/tests/integration.rs b/log_db/tests/integration.rs
index 3e712e1..2d2a4ca 100644
--- a/log_db/tests/integration.rs
+++ b/log_db/tests/integration.rs
@@ -10,12 +10,7 @@ use std::thread;
use std::time::Duration;
use tempfile::tempdir;
-#[ctor]
-fn init_logger() {
- let _ = env_logger::builder().is_test(true).try_init();
-}
-
-fn tmp_dir() -> String {
+pub fn tmp_dir() -> String {
let dir = tempdir()
.expect("Failed to create temporary directory")
.path()
@@ -26,6 +21,11 @@ fn tmp_dir() -> String {
dir
}
+#[ctor]
+fn init_logger() {
+ let _ = env_logger::builder().is_test(true).try_init();
+}
+
#[derive(Eq, PartialEq, Clone, Debug)]
enum Field {
Id,