HostProxy#

class pytest_bluezenv.HostProxy(path, timeout, name, progress_reporter=None)[source]#

Upper-tester representation of one VM host with loadable plugins.

Plugins are usually loaded by host_config, but may also be loaded during a test.

Loaded plugins appear as attributes on the host proxy.

Example

def test_bluetoothctl_show(hosts):
    host = hosts[0]
    host.load(Bluetoothctl())
    host.bluetoothctl.send("show\n")
__init__(path, timeout, name, progress_reporter=None)[source]#

Create a VM-host proxy.

Parameters:
  • path (str) – RPC socket path.

  • timeout (float) – default RPC timeout in seconds.

  • name (str) – VM-host logger name.

  • progress_reporter – optional progress reporter for RPC calls.

Methods

close()

Shutdown this VM host tester instance.

load(plugin)

Load given plugin to the VM host synchronously.

set_instance_name(name)

Name this VM host instance on the parent side and on the VM.

start_load(plugin)

Begin loading a plugin in the VM host.

wait_load([timeout])

Wait for plugin loads to complete, and make plugins available.