From 3c19ea0eccc25f983a9558d7120884d16b4721c4 Mon Sep 17 00:00:00 2001 From: Vika Date: Wed, 5 May 2021 16:33:54 +0300 Subject: Removed the in-memory database, it's dragging me down --- src/lib.rs | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'src/lib.rs') diff --git a/src/lib.rs b/src/lib.rs index 6a0a1cc..2fe87f4 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -81,17 +81,6 @@ pub async fn get_app_with_redis(token_endpoint: surf::Url, redis_uri: String, me equip_app(app) } -#[cfg(test)] -pub async fn get_app_with_memory_for_testing(token_endpoint: surf::Url) -> (database::MemoryStorage, App) { - let database = database::MemoryStorage::new(); - let app = tide::with_state(ApplicationState { - token_endpoint, media_endpoint: None, - storage: database.clone(), - http_client: surf::Client::new(), - }); - - return (database, equip_app(app)) -} #[cfg(test)] pub async fn get_app_with_test_redis(token_endpoint: surf::Url) -> (tempdir::TempDir, std::process::Child, database::RedisStorage, App) { let (tempdir, child, uri) = crate::database::get_redis_instance().await; -- cgit 1.4.1