start¶
Source code: start.py
A test to make sure everything is set for the following test in test list.
Description¶
This test checks everything is set for the following tests in the test list, including make sure an external power supplier is presence, checking factory software is installed, etc.
Normally, this test should be placed as the first one in a test list, to make sure everything is set before performing any other tests.
Test Procedure¶
It checks several conditions as specified by the options, and ask the operator to press a key to pass.
Dependency¶
If argument require_external_power
is set, it reads
/sys/class/power_supply/
to determine if an external power supply is
connected.
Examples¶
To initialize shared data, then ask the operator to press a key to continue, add this in test list:
{
"pytest_name": "start"
}
Ask the operator to press power button to continue, add this in test list:
{
"pytest_name": "start",
"args": {
"key_to_continue": "HW_BUTTON",
"button_key_name": "KEY_POWER",
"button_name": "i18n! Power Button"
}
}
Show custom message:
{
"pytest_name": "start",
"args": {
"prompt": "i18n! Some message..."
}
}
To also ensure if an external power supply is connected, and check factory toolkit is properly installed:
{
"pytest_name": "start",
"args": {
"check_factory_install_complete": true,
"require_external_power": true
}
}
Test Arguments¶
Name |
Type |
Description |
---|---|---|
key_to_continue |
[‘HW_BUTTON’, ‘NONE’, ‘SPACE’] |
(optional; default: |
button_key_name |
str, None |
(optional; default: |
button_name |
str, dict, None |
(optional; default: |
require_external_power |
bool |
(optional; default: |
check_factory_install_complete |
bool, None |
(optional; default: |
prompt |
str, dict, None |
(optional; default: |
init_shared_data |
dict |
(optional; default: |