refactor: LOW+MEDIUM cleanups — CQRS DiaryQuery/GoalCommand+GoalQuery,

test-helpers out of production, decompose get_user_profile_html,
dedup secure_flag, remove vestigial social_query, drop
PersistedImportSession, LoginCommand rename, DeleteAccountDeps,
PersonId macro, ReviewSortBy rename, TUI Command for fs::read,
generic PaginatedResponse<T>, noop ports for production fallbacks
This commit is contained in:
2026-07-10 05:29:02 +02:00
parent 5e0dde656c
commit 6a9b4e5c00
52 changed files with 405 additions and 298 deletions

View File

@@ -2,7 +2,7 @@ use std::sync::Arc;
use async_trait::async_trait;
use domain::errors::DomainError;
use domain::testing::{FakeDiaryRepository, NoopSocialQueryPort};
use domain::testing::{FakeDiaryQuery, NoopSocialQueryPort};
use crate::{
config::AppConfig, diary::deps::GetActivityFeedDeps, diary::get_activity_feed,
@@ -11,7 +11,7 @@ use crate::{
fn default_deps() -> GetActivityFeedDeps {
GetActivityFeedDeps {
diary: FakeDiaryRepository::new() as _,
diary: FakeDiaryQuery::new() as _,
social_query: Arc::new(NoopSocialQueryPort),
config: TestContextBuilder::new().config,
}
@@ -112,7 +112,7 @@ async fn following_filter_parses_local_and_remote_urls() {
let social = Arc::new(FakeSocialWithFollowing(following_urls));
let deps = GetActivityFeedDeps {
diary: FakeDiaryRepository::new() as _,
diary: FakeDiaryQuery::new() as _,
social_query: social as _,
config: AppConfig {
allow_registration: true,