test: refusing fakes, failure-path tests, shared panic stubs
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
use domain::testing::test_movie_with_year;
|
||||
use domain::testing::{NoopPersonCommand, test_movie_with_year};
|
||||
use std::sync::Arc;
|
||||
|
||||
use chrono::Utc;
|
||||
@@ -61,31 +61,6 @@ async fn stores_profile_and_indexes() {
|
||||
assert_eq!(profile_repo.movie_profile_count(), 1);
|
||||
}
|
||||
|
||||
struct NoopPersonCommand;
|
||||
|
||||
#[async_trait::async_trait]
|
||||
impl domain::ports::PersonCommand for NoopPersonCommand {
|
||||
async fn upsert_batch(
|
||||
&self,
|
||||
_: &[domain::models::Person],
|
||||
) -> Result<(), domain::errors::DomainError> {
|
||||
Ok(())
|
||||
}
|
||||
async fn backfill_from_credits_batch(
|
||||
&self,
|
||||
_: u32,
|
||||
) -> Result<(u64, bool), domain::errors::DomainError> {
|
||||
Ok((0, false))
|
||||
}
|
||||
async fn update_enrichment(
|
||||
&self,
|
||||
_: &domain::models::PersonId,
|
||||
_: &domain::models::PersonEnrichmentData,
|
||||
) -> Result<(), domain::errors::DomainError> {
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn extracts_and_indexes_persons() {
|
||||
let movie_repo = InMemoryStore::new();
|
||||
|
||||
Reference in New Issue
Block a user