[WIP] Integration of TestEnvironment

This commit is contained in:
Leonard Steppy 2025-03-30 00:28:00 +01:00
parent d87cd468cc
commit b381e6fa7f

View File

@ -22,6 +22,12 @@ pub struct TestEnvironment {
// TODO ssh servers and local server
}
#[derive(Debug)]
pub struct SshServer {
pub name: String,
pub home_dir: FsEntry,
}
#[derive(Debug)]
pub struct FsEntry {
pub name: OsString,
@ -30,14 +36,17 @@ pub struct FsEntry {
#[derive(Debug)]
pub enum FsEntryKind {
Directory {
entries: Vec<FsEntry>,
},
Directory(Dir),
File {
contents: String,
}
}
#[derive(Debug)]
pub struct Dir {
pub contents: Vec<FsEntry>,
}
impl Environment for TestEnvironment {
fn args_os(&self) -> Vec<OsString> {
self.args_os.clone()