Mbed Host Tests
|
Public Member Functions | |
__init__ (self) | |
generic_mbed_copy (self, image_path, destination_disk) | |
Generic mbed copy method for "mbed enabled" devices. | |
setup (self, *args, **kwargs) | |
execute (self, capability, *args, **kwargs) | |
Executes capability by name. | |
![]() | |
is_os_supported (self, os_name=None) | |
print_plugin_error (self, text) | |
Interface helper methods - overload only if you need to have custom behaviour. | |
print_plugin_info (self, text, NL=True) | |
Function prints notification in console and exits always with True. | |
print_plugin_char (self, char) | |
check_mount_point_ready (self, destination_disk, init_delay=0.2, loop_delay=0.25, target_id=None, timeout=60) | |
Waits until destination_disk is ready and can be accessed by e.g. | |
check_serial_port_ready (self, serial_port, target_id=None, timeout=60) | |
Function checks (using mbed-ls) and updates serial port name information for DUT with specified target_id. | |
check_parameters (self, capability, *args, **kwargs) | |
This function should be ran each time we call execute() to check if none of the required parameters is missing. | |
run_command (self, cmd, shell=True) | |
Runs command from command line. | |
mbed_os_info (self) | |
Returns information about host OS. | |
mbed_os_support (self) | |
Function used to determine host OS. | |
Static Public Attributes | |
str | name = 'HostTestPluginCopyMethod_Mbed' |
str | type = 'CopyMethod' |
bool | stable = True |
list | capabilities = ['shutil', 'default'] |
list | required_parameters = ['image_path', 'destination_disk'] |
![]() | |
str | name = "HostTestPluginBase" |
Interface: | |
str | type = "BasePlugin" |
list | capabilities = [] |
list | required_parameters = [] |
bool | stable = False |
Additional Inherited Members | |
![]() | |
plugin_logger = ht_loggers.get(self.type, ht_loggers['BasePlugin']) | |
Generic flashing method for mbed-enabled devices (by copy)
Definition at line 25 of file module_copy_mbed.py.
mbed_host_tests.host_tests_plugins.module_copy_mbed.HostTestPluginCopyMethod_Mbed.__init__ | ( | self | ) |
ctor
Reimplemented from mbed_host_tests.host_tests_plugins.host_test_plugins.HostTestPluginBase.
Definition at line 29 of file module_copy_mbed.py.
mbed_host_tests.host_tests_plugins.module_copy_mbed.HostTestPluginCopyMethod_Mbed.execute | ( | self, | |
capability, | |||
* | args, | ||
** | kwargs ) |
Executes capability by name.
Each capability may directly just call some command line program or execute building pythonic function
Reimplemented from mbed_host_tests.host_tests_plugins.host_test_plugins.HostTestPluginBase.
Definition at line 67 of file module_copy_mbed.py.
mbed_host_tests.host_tests_plugins.module_copy_mbed.HostTestPluginCopyMethod_Mbed.generic_mbed_copy | ( | self, | |
image_path, | |||
destination_disk ) |
Generic mbed copy method for "mbed enabled" devices.
image_path | Path to binary file to be flashed |
destination_disk | Path to destination (mbed mount point) |
It uses standard python shutil function to copy image_file (target specific binary) to device's disk.
Definition at line 34 of file module_copy_mbed.py.
mbed_host_tests.host_tests_plugins.module_copy_mbed.HostTestPluginCopyMethod_Mbed.setup | ( | self, | |
* | args, | ||
** | kwargs ) |
Configure plugin, this function should be called before plugin execute() method is used.
Reimplemented from mbed_host_tests.host_tests_plugins.host_test_plugins.HostTestPluginBase.
Definition at line 62 of file module_copy_mbed.py.
|
static |
Definition at line 59 of file module_copy_mbed.py.
|
static |
Definition at line 56 of file module_copy_mbed.py.
|
static |
Definition at line 60 of file module_copy_mbed.py.
|
static |
Definition at line 58 of file module_copy_mbed.py.
|
static |
Definition at line 57 of file module_copy_mbed.py.