pub mod agent; pub mod db; use std::{pin::Pin, sync::Arc}; use testcontainers::{ContainerAsync, GenericImage, TestcontainersError}; use crate::containers::{ agent::AgentContainerInfo, db::{ContainerizedDBInfo, PreExistingDBInfo}, }; pub type UnStartedContainer = Pin, TestcontainersError>> + Send>>; pub type AgentConfigInfoType = ConfigInfoType; pub type DBConfigInfoType = ConfigInfoType; pub trait WithContainer { fn container(&self) -> &Arc>; } pub trait WithoutContainer { fn on_delete(&self); } impl WithoutContainer for () { fn on_delete(&self) {} } #[derive(Clone)] pub enum ConfigInfoType where T: WithContainer, U: WithoutContainer, { Containerized(T), PreExisting(U), }