pub struct Component {
pub url: String,
pub name: String,
pub binary: String,
pub args: Vec<String>,
pub environ: Option<Vec<String>>,
pub ns: Namespace,
pub job: Job,
pub options: ProcessOptions,
pub config_vmo: Option<Vmo>,
pub component_instance: Option<Event>,
/* private fields */
}Expand description
All information about this test ELF component.
Fields§
§url: StringComponent URL
name: StringComponent name
binary: StringBinary path for this component relative to /pkg in ‘ns’
args: Vec<String>Arguments for this test.
environ: Option<Vec<String>>Environment variables for this test.
ns: NamespaceNamespace to pass to test process.
job: JobParent job in which all test processes should be executed.
options: ProcessOptionsOptions to create process with.
config_vmo: Option<Vmo>The structured config vmo.
component_instance: Option<Event>Component instance token, used only in tracing
Implementations§
Source§impl Component
impl Component
Sourcepub async fn new<F>(
start_info: ComponentStartInfo,
validate_args: F,
) -> Result<(Self, ServerEnd<DirectoryMarker>, ServerEnd<DirectoryMarker>), ComponentError>
pub async fn new<F>( start_info: ComponentStartInfo, validate_args: F, ) -> Result<(Self, ServerEnd<DirectoryMarker>, ServerEnd<DirectoryMarker>), ComponentError>
Create new object using ComponentStartInfo.
On success returns self and outgoing_dir from ComponentStartInfo.
pub fn config_vmo(&self) -> Result<Option<Vmo>, ComponentError>
pub fn executable_vmo(&self) -> Result<Vmo, ComponentError>
pub fn loader_service(&self, loader: ServerEnd<LoaderMarker>)
pub async fn create_for_tests(args: BuilderArgs) -> Result<Self, ComponentError>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Component
impl !RefUnwindSafe for Component
impl Send for Component
impl Sync for Component
impl Unpin for Component
impl !UnwindSafe for Component
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, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
Source§impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
§impl<T> InstanceFromServiceTransport<T> for T
impl<T> InstanceFromServiceTransport<T> for T
§fn from_service_transport(handle: T) -> T
fn from_service_transport(handle: T) -> T
Converts the given service transport handle of type
T to [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