mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract Class Reference
Inheritance diagram for mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract:

## Public Member Functions

def | notify_complete (self, result=None)
| Notify main even loop that host test finished processing. More...
def | reset_dut (self, value)
def | reset (self)
def | notify_conn_lost (self, text)
| Notify main even loop that there was a DUT-host test connection error. More...
def | log (self, text)
| Send log message to main event loop. More...
def | send_kv (self, key, value)
| Send Key-Value data to DUT. More...
def | setup_communication (self, event_queue, dut_event_queue, config={})
| Setup queues used for IPC. More...
def | get_config_item (self, name)
def | setup (self)
| Setup your tests and callbacks. More...
def | result (self)
| Returns host test result (True, False or None) More...
def | teardown (self)
| Blocking always guaranteed test teardown. More...

## Static Public Attributes

string | name = ''
| script_location = None

## Detailed Description

    Base class for each host-test test cases with standard
        setup, test and teardown set of functions

Definition at line 24 of file base_host_test.py.

## Member Function Documentation

## get_config_item()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.get_config_item | ( |  | self,
|  |  | name
| ) |  |

    Return test config

    :param name:
    :return:

Definition at line 95 of file base_host_test.py.

## log()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.log | ( |  | self,
|  |  | text
| ) |  |

Send log message to main event loop.

Definition at line 81 of file base_host_test.py.

## notify_complete()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.notify_complete | ( |  | self,
|  |  | result = `None`
| ) |  |

Notify main even loop that host test finished processing.

Parameters

  result | True for success, False failure. If None - no action in main even loop

Definition at line 52 of file base_host_test.py.

## notify_conn_lost()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.notify_conn_lost | ( |  | self,
|  |  | text
| ) |  |

Notify main even loop that there was a DUT-host test connection error.

Parameters

  consume | If True htrun will process (consume) all remaining events

Definition at line 75 of file base_host_test.py.

## reset()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.reset | ( |  | self | ) |

    Reset the device under test and continue running the host test
    :return:

Definition at line 67 of file base_host_test.py.

## reset_dut()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.reset_dut | ( |  | self,
|  |  | value
| ) |  |

    Reset device under test
    :return:

Definition at line 59 of file base_host_test.py.

## result()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.result | ( |  | self | ) |

Returns host test result (True, False or None)

Definition at line 108 of file base_host_test.py.

## send_kv()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.send_kv | ( |  | self,
|  |  | key,
|  |  | value
| ) |  |

Send Key-Value data to DUT.

Definition at line 85 of file base_host_test.py.

## setup()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.setup | ( |  | self | ) |

Setup your tests and callbacks.

Definition at line 104 of file base_host_test.py.

## setup_communication()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.setup_communication | ( |  | self,
|  |  | event_queue,
|  |  | dut_event_queue,
|  |  | config = `{}`
| ) |  |

Setup queues used for IPC.

Definition at line 89 of file base_host_test.py.

## teardown()

def mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.teardown | ( |  | self | ) |

Blocking always guaranteed test teardown.

Definition at line 112 of file base_host_test.py.

## Member Data Documentation

## name

string mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.name = ''

static

Definition at line 29 of file base_host_test.py.

## script_location

mbed_host_tests.host_tests.base_host_test.BaseHostTestAbstract.script_location = None

static

Definition at line 32 of file base_host_test.py.

The documentation for this class was generated from the following file:

- mbed_host_tests/host_tests/base_host_test.py