Documentation ¶
Index ¶
- Constants
- Variables
- type Asset
- type Client
- func (c *Client) Close()
- func (c *Client) FileDelete(ctx context.Context, path string) error
- func (c *Client) FileRead(ctx context.Context, path string) ([]byte, error)
- func (c *Client) FileWrite(ctx context.Context, path string, buf []byte) error
- func (c *Client) GetSystemImageMerkle(ctx context.Context) (string, error)
- func (c *Client) PathExists(ctx context.Context, path string) (bool, error)
- func (c *Client) PathStat(ctx context.Context, path string) (PathMetadata, error)
- func (c *Client) PaverQueryActiveConfiguration(ctx context.Context) (Configuration, error)
- func (c *Client) PaverQueryConfigurationStatus(ctx context.Context, configuration Configuration) (ConfigurationStatus, error)
- func (c *Client) PaverQueryCurrentConfiguration(ctx context.Context) (Configuration, error)
- func (c *Client) PaverReadAsset(ctx context.Context, configuration Configuration, asset Asset) ([]byte, error)
- func (c *Client) ValidateStaticPackages(ctx context.Context) error
- type Configuration
- type ConfigurationStatus
- type PathMetadata
Constants ¶
const ( ConfigurationA Configuration = "a" ConfigurationB = "b" ConfigurationRecovery = "recovery" )
const ( ConfigurationStatusHealthy ConfigurationStatus = "healthy" ConfigurationStatusPending = "pending" ConfigurationStatusUnbootable = "unbootable" )
Variables ¶
var ErrInvalidPaverMethod error = errors.New("Invalid paver facade method")
var ErrNotSupported error = errors.New("not supported")
Functions ¶
This section is empty.
Types ¶
type Asset ¶
type Asset string
const ( AssetKernel Asset = "kernel" AssetVerifiedBootMetadata = "verified_boot_metadata" )
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is a wrapper around sl4f that supports auto-installing and starting sl4f on the target.
If the target already has sl4f running, this client will not start a new instance.
This client requires the target to contain the "pkgctl" binary and for the target to have the "run" and "sl4f" packages available at "fuchsia-pkg://host_target_testing_sl4f".
func (*Client) FileDelete ¶
FileDelete deletes the given path from the target, failing if it does not exist.
func (*Client) GetSystemImageMerkle ¶
GetSystemImageMerkle returns the merkle root of the system_image package
func (*Client) PathExists ¶
PathExists determines if the path exists on the target.
func (*Client) PathStat ¶
PathStat deletes the given path from the target, failing if it does not exist.
func (*Client) PaverQueryActiveConfiguration ¶
func (c *Client) PaverQueryActiveConfiguration(ctx context.Context) (Configuration, error)
PaverQueryActiveConfiguration determines the active boot configuration of the target, if supported.
func (*Client) PaverQueryConfigurationStatus ¶
func (c *Client) PaverQueryConfigurationStatus(ctx context.Context, configuration Configuration) (ConfigurationStatus, error)
PaverQueryConfigurationStatus determines the status of the given boot slot, if supported.
func (*Client) PaverQueryCurrentConfiguration ¶
func (c *Client) PaverQueryCurrentConfiguration(ctx context.Context) (Configuration, error)
PaverQueryCurrentConfiguration determines the active boot configuration of the target, if supported.
func (*Client) PaverReadAsset ¶
func (c *Client) PaverReadAsset(ctx context.Context, configuration Configuration, asset Asset) ([]byte, error)
PaverReadAsset reads the requested asset from the device.
type Configuration ¶
type Configuration string
type ConfigurationStatus ¶
type ConfigurationStatus string