presentation wiring

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-04 09:30:20 +02:00
parent 97a496553a
commit 79a06e6844
18 changed files with 883 additions and 18 deletions

View File

@@ -4,3 +4,5 @@ version = "0.1.0"
edition = "2024"
[dependencies]
async-trait = { workspace = true }
domain = { workspace = true }

View File

@@ -1,14 +1,13 @@
pub fn add(left: u64, right: u64) -> u64 {
left + right
}
use async_trait::async_trait;
use domain::{errors::DomainError, ports::AuthService, value_objects::UserId};
#[cfg(test)]
mod tests {
use super::*;
pub struct StubAuthService;
#[test]
fn it_works() {
let result = add(2, 2);
assert_eq!(result, 4);
#[async_trait]
impl AuthService for StubAuthService {
async fn validate_token(&self, _token: &str) -> Result<UserId, DomainError> {
Err(DomainError::InfrastructureError(
"auth service not implemented".into(),
))
}
}