blob: 2852ef66c30bee67482c1c083b80c8c8619b5017 [file] [log] [blame]
Chase Qi09edc7f2016-08-18 13:18:50 +08001Getting started
2===============
3 git clone https://git.linaro.org/qa/test-definitions.git
4 cd ./test-definitions
5 . ./automated/bin/setenv.sh
6 test-runner -h
7
8Running test
9============
10Both test script and corresponding test definition files provided in the same
11folder that named with the test case name.
12
13Test script can be run independently, you may need to specify parameters
14manually as needed.
15
16Test definition file in YAML format created for each test to
17 - Define default test parameters
18 - Run test with local test-runner, which supports to run a set of tests
19 defined in agenda file, customized parameters are supported as well.
20 - Run test in LAVA(Linaro Automation and Validation Architecture)
21
22Running test script
23------------------
24linux:
25 cd ./automated/linux/smoke/
26 ./smoke.sh
27 # skip package installation.
28 ./smoke.sh -s true
29
30android:
31 cd ./automated/android/dd-wr-speed/
32 ./dd-wr-speed.sh
33 # Specify SN when more than one device connected.
34 ./dd-wr-speed.sh -s "serial_no"
35 # Specify other params.
36 ./dd-wr-speed.sh -i "10" -p "/dev/block/mmcblk1p1"
37
38Using test-runner
39----------------
40single test run:
41 test-runner -d ./automated/linux/smoke/smoke.yaml
42 # skip package install
43 test-runner -d ./automated/linux/smoke/smoke.yaml -s
44
45running test plan:
46 # Run a set of tests defined in agenda file.
Chase Qi9752efa2017-07-21 16:02:58 +080047 test-runner -p ./plans/linux-example.yaml
Chase Qia158efe2017-11-17 12:35:11 +080048 # Apply test plan overlay to skip, amend or add tests.
49 test-runner -p ./plans/linux-example.yaml -O test-plan-overlay-example.yaml
Chase Qi09edc7f2016-08-18 13:18:50 +080050
51Collecting result
52=================
53Please find test results in the following locations.
54 - ${OUTPUT} and ${RESULT_FILE} for each test are defined in the test case.
55 - test-runner parse stdout.log and save result to ${test_path}
56 - test-runner combines results of executed tests and save them in
57 ${OUTPUT}/results.csv,
58 - ${OUTPUT} path of test-runner can be modified with '-o'
Dan Ruef51ede72017-06-07 16:50:33 -050059
60Contributing
61============
62
63Changes need to be able to pass the following check, which will check files in
64the most recent commit:
65
66 python3 validate.py -g -s SC1091
67
68To develop locally, there are Dockerfiles in test/ that can be used to simulate
69target environments. The easiest way to use is to run `test.sh
70[debian|centos]`. test.sh will run validate.py, and then build the Docker
71environment specified, run plans/linux-example.yaml, and then drop into a bash
72shell inside the container so that things like /root/output can be inspected.
73It is not (yet) a pass/fail test; merely a development helper and validation
74environment.