Crate blackout_target

source ·
Expand description

library for target side of filesystem integrity host-target interaction tests

Modules

Generate a random directory tree that can be commited to disk all at once. The general formula goes like this -

Structs

A test server, which serves the fuchsia.blackout.test.Controller protocol.

Traits

The three steps the target-side of a blackout test needs to implement.

Functions

Returns a directory proxy connected to /dev.
Find the device in /dev/class/block that represents a given topological path. Returns the full path of the device in /dev/class/block.
During the test or verify steps, finds a block device which represents an fvm partition named [partition_label]. If [device_path] is provided, this assumes the partition is on that device. Returns the topological path to the device, only returning once the device is enumerated, so it can be used immediately.
Generate a Vec of random bytes from a seed using a standard distribution.
During the setup step, formats a device with fvm, creating a single partition named [partition_label]. If [device_path] is None, finds a device which already had fvm, erase it, and then set it up in this way. Returns the path to the device with the created partition, only once the device is enumerated, so it can be used immediately.