feat/with-archiver #2
@ -129,7 +129,7 @@ impl Archive {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub struct ArchiveFile {
|
pub struct ArchiveFile {
|
||||||
content: Vec<u8>,
|
pub content: Vec<u8>,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl From<Vec<u8>> for ArchiveFile {
|
impl From<Vec<u8>> for ArchiveFile {
|
||||||
|
@ -67,7 +67,7 @@ pub mod models;
|
|||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod test {
|
mod test {
|
||||||
use crate::services::archive::MockArchive;
|
use crate::services::archive::{ArchiveFile, MockArchive};
|
||||||
use crate::services::domain_events::MockDomainEvents;
|
use crate::services::domain_events::MockDomainEvents;
|
||||||
use crate::services::file_reader::{Files, MockFileReader};
|
use crate::services::file_reader::{Files, MockFileReader};
|
||||||
use crate::services::file_store::MockFileStore;
|
use crate::services::file_store::MockFileStore;
|
||||||
@ -95,6 +95,11 @@ mod test {
|
|||||||
.returning(|_| Ok(Files::default()));
|
.returning(|_| Ok(Files::default()));
|
||||||
|
|
||||||
let mut archive = MockArchive::default();
|
let mut archive = MockArchive::default();
|
||||||
|
archive.expect_create_archive().times(1).returning(|_| {
|
||||||
|
Ok(ArchiveFile {
|
||||||
|
content: Vec::new(),
|
||||||
|
})
|
||||||
|
});
|
||||||
|
|
||||||
let releaser_manager = ReleaseManager::new(file_reader, file_store, archive, domain_events);
|
let releaser_manager = ReleaseManager::new(file_reader, file_store, archive, domain_events);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user