Struct cargo_test_support::containers::MkFile
source · pub struct MkFile { /* private fields */ }
Expand description
Builder for configuring a file to copy into a container.
Implementations§
source§impl MkFile
impl MkFile
sourcepub fn path(path: &str) -> MkFile
pub fn path(path: &str) -> MkFile
Defines a file to add to the container.
This should be passed to Container::file
.
The path is the path inside the container to create the file.
pub fn contents(self, contents: impl Into<Vec<u8>>) -> Self
pub fn mode(self, mode: u32) -> Self
pub fn uid(self, uid: u64) -> Self
pub fn gid(self, gid: u64) -> Self
Auto Trait Implementations§
impl Freeze for MkFile
impl RefUnwindSafe for MkFile
impl Send for MkFile
impl Sync for MkFile
impl Unpin for MkFile
impl UnwindSafe for MkFile
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more