refactor: eliminate User/UserResponse struct literals, add AP user tests
- Feed/search adapters use #[sqlx(flatten)] UserRow instead of inline User construction — single point of change when User gains fields - User::new_remote constructor replaces struct literal in testing - to_summary_response replaces inline UserResponse in get_users - 5 integration tests for PgApUserRepository (find, count, profile_fields→attachment)
This commit is contained in:
@@ -5,6 +5,7 @@ use domain::{
|
||||
user::User,
|
||||
},
|
||||
ports::{SearchPort, ThoughtRepository, UserWriter},
|
||||
value_objects::{Content, Email, PasswordHash, ThoughtId, UserId, Username},
|
||||
};
|
||||
|
||||
async fn seed_thought(pool: &sqlx::PgPool, username: &str, content: &str) -> (User, Thought) {
|
||||
|
||||
Reference in New Issue
Block a user