From 54e7e2aa1410add7e09b7f76039cd5baf6bde585 Mon Sep 17 00:00:00 2001 From: Ryan Harkin Date: Tue, 2 Feb 2021 09:23:17 +0000 Subject: Add Schneider Test Plan infrastructure Signed-off-by: Ryan Harkin --- manual/se/lynis.yaml | 33 ++++++++ manual/se/mbedtls-internal.yaml | 36 +++++++++ manual/se/mbedtls.yaml | 87 ++++++++++++++++++++ manual/se/tb12.yaml | 23 ++++++ manual/se/tb13.yaml | 23 ++++++ manual/se/tb14.yaml | 22 +++++ manual/se/tb15.yaml | 22 +++++ manual/se/tb16.yaml | 22 +++++ manual/se/tb17.yaml | 22 +++++ manual/se/tb18.yaml | 32 ++++++++ manual/se/tb19.yaml | 23 ++++++ manual/se/tb20.yaml | 22 +++++ manual/se/tb21.yaml | 27 +++++++ manual/se/tb22.yaml | 24 ++++++ manual/se/tb23.yaml | 22 +++++ manual/se/tb24.yaml | 22 +++++ manual/se/tb25.yaml | 22 +++++ manual/se/tb26.yaml | 22 +++++ manual/se/tb27.yaml | 22 +++++ manual/se/tb28.yaml | 22 +++++ manual/se/tb29.yaml | 22 +++++ manual/se/tb30.yaml | 22 +++++ manual/se/tb31.yaml | 28 +++++++ manual/se/tb32.yaml | 50 ++++++++++++ manual/se/tb33.yaml | 25 ++++++ manual/se/tb34.yaml | 38 +++++++++ manual/se/tb35.yaml | 25 ++++++ manual/se/tb36.yaml | 33 ++++++++ manual/se/tb37.yaml | 22 +++++ manual/se/tb38.yaml | 22 +++++ manual/se/tb40.yaml | 23 ++++++ manual/se/tb41.yaml | 23 ++++++ manual/se/tc1.yaml | 23 ++++++ manual/se/tc16.yaml | 68 ++++++++++++++++ manual/se/tc17.yaml | 26 ++++++ manual/se/tc18.yaml | 22 +++++ manual/se/tc19.yaml | 37 +++++++++ manual/se/tc2.yaml | 23 ++++++ manual/se/tc20.yaml | 22 +++++ manual/se/tc21.yaml | 27 +++++++ manual/se/tc22.yaml | 32 ++++++++ manual/se/tc23.yaml | 28 +++++++ manual/se/tc25.yaml | 49 ++++++++++++ manual/se/tc26.yaml | 45 +++++++++++ manual/se/tc27.yaml | 22 +++++ manual/se/tc28.yaml | 22 +++++ manual/se/tc29.yaml | 42 ++++++++++ manual/se/tc3.yaml | 23 ++++++ manual/se/tc30.yaml | 45 +++++++++++ manual/se/tc31.yaml | 27 +++++++ manual/se/tc32.yaml | 24 ++++++ manual/se/tc33.yaml | 37 +++++++++ manual/se/tc34.yaml | 22 +++++ manual/se/tc35.yaml | 28 +++++++ manual/se/tc36.yaml | 91 +++++++++++++++++++++ manual/se/tc37.yaml | 44 ++++++++++ manual/se/tc38.yaml | 22 +++++ manual/se/tc39.yaml | 34 ++++++++ manual/se/tc40.yaml | 22 +++++ manual/se/tc41.yaml | 37 +++++++++ manual/se/tc42.yaml | 22 +++++ manual/se/tc43.yaml | 22 +++++ manual/se/tc44.yaml | 99 +++++++++++++++++++++++ manual/se/tc45.yaml | 43 ++++++++++ manual/se/tc46.yaml | 22 +++++ manual/se/tc47.yaml | 22 +++++ manual/se/tc48.yaml | 29 +++++++ manual/se/tc49.yaml | 29 +++++++ manual/se/tc5.yaml | 23 ++++++ manual/se/tc50.yaml | 23 ++++++ manual/se/tc7.yaml | 23 ++++++ manual/se/tc8.yaml | 27 +++++++ manual/se/tc9.yaml | 23 ++++++ plans/se-auto.yaml | 172 ++++++++++++++++++++++++++++++++++++++++ plans/se-tb-template.yaml | 72 +++++++++++++++++ plans/se-template.yaml | 17 ++++ se-generate.sh | 85 ++++++++++++++++++++ 77 files changed, 2580 insertions(+) create mode 100644 manual/se/lynis.yaml create mode 100644 manual/se/mbedtls-internal.yaml create mode 100644 manual/se/mbedtls.yaml create mode 100644 manual/se/tb12.yaml create mode 100644 manual/se/tb13.yaml create mode 100644 manual/se/tb14.yaml create mode 100644 manual/se/tb15.yaml create mode 100644 manual/se/tb16.yaml create mode 100644 manual/se/tb17.yaml create mode 100644 manual/se/tb18.yaml create mode 100644 manual/se/tb19.yaml create mode 100644 manual/se/tb20.yaml create mode 100644 manual/se/tb21.yaml create mode 100644 manual/se/tb22.yaml create mode 100644 manual/se/tb23.yaml create mode 100644 manual/se/tb24.yaml create mode 100644 manual/se/tb25.yaml create mode 100644 manual/se/tb26.yaml create mode 100644 manual/se/tb27.yaml create mode 100644 manual/se/tb28.yaml create mode 100644 manual/se/tb29.yaml create mode 100644 manual/se/tb30.yaml create mode 100644 manual/se/tb31.yaml create mode 100644 manual/se/tb32.yaml create mode 100644 manual/se/tb33.yaml create mode 100644 manual/se/tb34.yaml create mode 100644 manual/se/tb35.yaml create mode 100644 manual/se/tb36.yaml create mode 100644 manual/se/tb37.yaml create mode 100644 manual/se/tb38.yaml create mode 100644 manual/se/tb40.yaml create mode 100644 manual/se/tb41.yaml create mode 100644 manual/se/tc1.yaml create mode 100644 manual/se/tc16.yaml create mode 100644 manual/se/tc17.yaml create mode 100644 manual/se/tc18.yaml create mode 100644 manual/se/tc19.yaml create mode 100644 manual/se/tc2.yaml create mode 100644 manual/se/tc20.yaml create mode 100644 manual/se/tc21.yaml create mode 100644 manual/se/tc22.yaml create mode 100644 manual/se/tc23.yaml create mode 100644 manual/se/tc25.yaml create mode 100644 manual/se/tc26.yaml create mode 100644 manual/se/tc27.yaml create mode 100644 manual/se/tc28.yaml create mode 100644 manual/se/tc29.yaml create mode 100644 manual/se/tc3.yaml create mode 100644 manual/se/tc30.yaml create mode 100644 manual/se/tc31.yaml create mode 100644 manual/se/tc32.yaml create mode 100644 manual/se/tc33.yaml create mode 100644 manual/se/tc34.yaml create mode 100644 manual/se/tc35.yaml create mode 100644 manual/se/tc36.yaml create mode 100644 manual/se/tc37.yaml create mode 100644 manual/se/tc38.yaml create mode 100644 manual/se/tc39.yaml create mode 100644 manual/se/tc40.yaml create mode 100644 manual/se/tc41.yaml create mode 100644 manual/se/tc42.yaml create mode 100644 manual/se/tc43.yaml create mode 100644 manual/se/tc44.yaml create mode 100644 manual/se/tc45.yaml create mode 100644 manual/se/tc46.yaml create mode 100644 manual/se/tc47.yaml create mode 100644 manual/se/tc48.yaml create mode 100644 manual/se/tc49.yaml create mode 100644 manual/se/tc5.yaml create mode 100644 manual/se/tc50.yaml create mode 100644 manual/se/tc7.yaml create mode 100644 manual/se/tc8.yaml create mode 100644 manual/se/tc9.yaml create mode 100644 plans/se-auto.yaml create mode 100644 plans/se-tb-template.yaml create mode 100644 plans/se-template.yaml create mode 100755 se-generate.sh diff --git a/manual/se/lynis.yaml b/manual/se/lynis.yaml new file mode 100644 index 0000000..04a6d91 --- /dev/null +++ b/manual/se/lynis.yaml @@ -0,0 +1,33 @@ +metadata: + name: Lynis + format: "Manual Test Definition 1.0" + description: "Generate Lynis report" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "lynis audit system" + - "Check the output of the commands" + - "Save the logs and add to the release bundle and report" + - "/var/log/lynis.log" + - "/var/log/lynis-report.dat" + - "BOARD=soca9" + - "BOARD=lces2" + - "KERNEL_VERSION=4.9" + - "KERNEL_VERSION=4.19" + - "scp /var/log/lynis.log ryan@192.168.1.11:/linaro/schneider/release/2019.09-warrior.2/logs/lynis.log.${BOARD}-${KERNEL_VERSION}" + - "scp /var/log/lynis-report.dat ryan@192.168.1.11:/linaro/schneider/release/2019.09-warrior.2/logs/lynis-report.dat.${BOARD}-${KERNEL_VERSION}" + + expected: + - "Log files are generated and saved for the release report." + diff --git a/manual/se/mbedtls-internal.yaml b/manual/se/mbedtls-internal.yaml new file mode 100644 index 0000000..6e00b71 --- /dev/null +++ b/manual/se/mbedtls-internal.yaml @@ -0,0 +1,36 @@ +metadata: + name: mbedtls-internal + format: "Manual Test Definition 1.0" + description: "Run the internal mbedtls test suite" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + environment: + - manual-test + +run: + steps: + - "You may need to rebase to the latest se/mbedtls-2.16 branch" + - " " + - "git clone ssh://git@dev-private-git.linaro.org/schneider/mbedtls.git -b rmh-2.16.8" + - "git log --oneline -1" + - "e3f460832 2020-03-10 enable trustm" + - " " + - "scp -r ryan@192.168.1.11:/linaro/schneider/g.l.o/mbedtls ." + - "cd mbedtls" + - "mkdir build" + - "cd build" + - "cmake -DUSE_SHARED_MBEDTLS_LIBRARY=ON -DENABLE_PROGRAMS=ON -DENABLE_TESTING=ON -DENABLE_HW_TRUSTM_SUPPORT=ON -Wno-dev CMAKE_BUILD_TYPE=CheckFull .." + - "make" + - "make test" + + expected: + - "# Expect all tests to pass, except for these failures:" + - "63/73 Test #63: pkwrite-suite ....................***Failed 0.36 sec" + - "73/73 Test #73: x509write-suite ..................***Failed 30.52 sec" + diff --git a/manual/se/mbedtls.yaml b/manual/se/mbedtls.yaml new file mode 100644 index 0000000..7fb79cf --- /dev/null +++ b/manual/se/mbedtls.yaml @@ -0,0 +1,87 @@ +metadata: + name: mbedtls + format: "Manual Test Definition 1.0" + description: "Run the mbedtls test suite" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + environment: + - manual-test + +run: + steps: + - "You may need to rebase to the latest se/mbedtls-2.16 branch" + - " " + - "git clone ssh://git@dev-private-git.linaro.org/schneider/mbedtls.git -b rmh-2.16.8" + - "git log --oneline -1" + - "e3f460832 2020-03-10 enable trustm" + - " " + - "scp -r ryan@192.168.1.11:/linaro/schneider/g.l.o/mbedtls ." + - "cd mbedtls" + - "mkdir build" + - "cd build" + - "cmake -DUSE_SHARED_MBEDTLS_LIBRARY=ON -DENABLE_PROGRAMS=ON -DENABLE_TESTING=ON -DENABLE_HW_TRUSTM_SUPPORT=ON -Wno-dev .." + - "make" + - " " + - "# note: make takes a long time, 10 minutes or more?" + - "# You should have all these files to be able to run the test:" + - "ls -al \\" + - "./tests/test_suite_pk_sks \\" + - "./tests/test_suite_pk_sks.datax \\" + - "./tests/data_files/sks_parsePEM_2.key \\" + - "./tests/data_files/sks_parsePEM_1.key \\" + - "./tests/data_files/sks_parsePEM_3.key" + - " " + - "# First time when using a new trustm module" + - "# note: the app came from an email from Milan. I have it in my tools repo:" + - "./trustm_configure sample-activate" + - " " + - "# To run the tests, do this" + - "cd tests" + - "./test_suite_pk_sks" + + expected: + - "Example output:" + - " " + - "root@rzn1-snarc:~/mbedtls/build/tests# ./test_suite_pk_sks" + - "PK_SKS #1 unknown sks handler ..................................... PASS" + - "PK_SKS #2 self_test sks handler ................................... PASS" + - "PK_SKS #3 invalid sks name ........................................ PASS" + - "PK_SKS #4 Write SKS PEM file (bad handler) ........................ PASS" + - "PK_SKS #5 Write SKS PEM file (too long sks name) .................. PASS" + - "PK_SKS #6 Write SKS PEM file (check simple descriptor) ............ PASS" + - "PK_SKS #7 Write SKS PEM file (check big key id) ................... PASS" + - "PK_SKS #8 Parse SKS key descriptor (Simple descriptor) ............ PASS" + - "PK_SKS #9 Parse SKS key descriptor (Null descriptor) .............. PASS" + - "PK_SKS #10 Parse SKS key descriptor (No delimiter) ................ PASS" + - "PK_SKS #11 Parse SKS key descriptor (Trail delimiter) ............. PASS" + - "PK_SKS #12 Parse SKS key descriptor (Trim delimiter) .............. PASS" + - "PK_SKS #13 Parse SKS key descriptor (Only delimiter) .............. PASS" + - "PK_SKS #14 Parse SKS key descriptor (Invalid integer type) ........ PASS" + - "PK_SKS #15 Parse SKS key descriptor (Invalid integer format) ...... PASS" + - "PK_SKS #16 Parse SKS key descriptor (Unknown SKS handler) ......... PASS" + - "PK_SKS #17 Parse SKS key descriptor (One digit key ID) ............ PASS" + - "PK_SKS #18 Parse SKS key descriptor (Simple int key ID) ........... PASS" + - "PK_SKS #19 Parse SKS key descriptor (Long int key ID) ............. PASS" + - "PK_SKS #20 Parse SKS PEM file sks_parsePEM_1.key .................. PASS" + - "PK_SKS #21 Parse SKS PEM file sks_parsePEM_2.key .................. PASS" + - "PK_SKS #22 Parse SKS PEM file sks_parsePEM_3.key .................. PASS" + - "TrustM verify sks handler ......................................... PASS" + - "TrustM ECC-Genuine ................................................ PASS" + - "TrustM ECC-Machine keypair (gen) .................................. PASS" + - "TrustM ECC-Machine keypair (default) .............................. PASS" + - "TrustM #3 ECC-Machine pubkey (default) ............................ PASS" + - "TrustM #4 Sign/verify ECC-Machine ................................. PASS" + - "TrustM #5 SKS generated CSR with ECC-Machine ...................... PASS" + - "TrustM #6 Parse SKS PEM key format (Genuine) ...................... PASS" + - "TrustM #7 Parse SKS PEM key format (Machine ECC) .................. PASS" + - " " + - "----------------------------------------------------------------------------" + - " " + - "PASSED (31 / 31 tests (0 skipped))" + diff --git a/manual/se/tb12.yaml b/manual/se/tb12.yaml new file mode 100644 index 0000000..cfc06f0 --- /dev/null +++ b/manual/se/tb12.yaml @@ -0,0 +1,23 @@ +metadata: + name: TB12 + format: "Manual Test Definition 1.0" + description: "TB12: Insert USB stick" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" + diff --git a/manual/se/tb13.yaml b/manual/se/tb13.yaml new file mode 100644 index 0000000..8ddfcbc --- /dev/null +++ b/manual/se/tb13.yaml @@ -0,0 +1,23 @@ +metadata: + name: TB13 + format: "Manual Test Definition 1.0" + description: "TB13: Mount USB stick" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" + diff --git a/manual/se/tb14.yaml b/manual/se/tb14.yaml new file mode 100644 index 0000000..dde78cb --- /dev/null +++ b/manual/se/tb14.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB14 + format: "Manual Test Definition 1.0" + description: "TB14: remove USB stick" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" diff --git a/manual/se/tb15.yaml b/manual/se/tb15.yaml new file mode 100644 index 0000000..3ee908e --- /dev/null +++ b/manual/se/tb15.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB15 + format: "Manual Test Definition 1.0" + description: "TB15: Bulk Data Transfer" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" diff --git a/manual/se/tb16.yaml b/manual/se/tb16.yaml new file mode 100644 index 0000000..b2974d2 --- /dev/null +++ b/manual/se/tb16.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB16 + format: "Manual Test Definition 1.0" + description: "TB16: " + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" diff --git a/manual/se/tb17.yaml b/manual/se/tb17.yaml new file mode 100644 index 0000000..11dfd65 --- /dev/null +++ b/manual/se/tb17.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB17 + format: "Manual Test Definition 1.0" + description: "TB17: " + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" diff --git a/manual/se/tb18.yaml b/manual/se/tb18.yaml new file mode 100644 index 0000000..a4e4a6c --- /dev/null +++ b/manual/se/tb18.yaml @@ -0,0 +1,32 @@ +metadata: + name: TB18 + format: "Manual Test Definition 1.0" + description: "TB18: ttyGS0 to ttyACM0" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - soca9 + environment: + - manual-test + +run: + steps: + - "on the target" + - "cat /dev/ttyGS0" + - " " + - "on the host" + - "echo hello > /dev/ttyACM0" + - " " + - "on the host" + - "cat /dev/ttyACM0" + - " " + - "on the target" + - "echo test > /dev/ttyGS0" + + expected: + - "skip on lces2" + - "Data transferred OK on SoCA9" diff --git a/manual/se/tb19.yaml b/manual/se/tb19.yaml new file mode 100644 index 0000000..d7600cf --- /dev/null +++ b/manual/se/tb19.yaml @@ -0,0 +1,23 @@ +metadata: + name: TB19 + format: "Manual Test Definition 1.0" + description: "TB19: MMC device exists" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" + diff --git a/manual/se/tb20.yaml b/manual/se/tb20.yaml new file mode 100644 index 0000000..fe9834e --- /dev/null +++ b/manual/se/tb20.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB20 + format: "Manual Test Definition 1.0" + description: "TB20: MMC card partitions detected" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "This tests runs in LAVA" + + expected: + - "pass" diff --git a/manual/se/tb21.yaml b/manual/se/tb21.yaml new file mode 100644 index 0000000..b5332f6 --- /dev/null +++ b/manual/se/tb21.yaml @@ -0,0 +1,27 @@ +metadata: + name: TB21 + format: "Manual Test Definition 1.0" + description: "TB21: timer devices exist" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "soca9:" + - "clk=timer0" + - "lces2:" + - "clk=rzn1-timer1:2" + - " " + - "cat /proc/timer_list | grep ${clk}" + + expected: + - "timers exist" diff --git a/manual/se/tb22.yaml b/manual/se/tb22.yaml new file mode 100644 index 0000000..aad9de4 --- /dev/null +++ b/manual/se/tb22.yaml @@ -0,0 +1,24 @@ +metadata: + name: TB22 + format: "Manual Test Definition 1.0" + description: "TB22: available clocksource" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "cat /sys/devices/system/clocksource/clocksource0/available_clocksource" + + + expected: + - "SoCA9 has timer1" + - "LCES2 has rzn1_timer_clocksource" diff --git a/manual/se/tb23.yaml b/manual/se/tb23.yaml new file mode 100644 index 0000000..ede6f70 --- /dev/null +++ b/manual/se/tb23.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB23 + format: "Manual Test Definition 1.0" + description: "TB23: CAN Bus" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" diff --git a/manual/se/tb24.yaml b/manual/se/tb24.yaml new file mode 100644 index 0000000..fa3469c --- /dev/null +++ b/manual/se/tb24.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB24 + format: "Manual Test Definition 1.0" + description: "TB24: CAN Bus" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" diff --git a/manual/se/tb25.yaml b/manual/se/tb25.yaml new file mode 100644 index 0000000..67e6c22 --- /dev/null +++ b/manual/se/tb25.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB25 + format: "Manual Test Definition 1.0" + description: "TB25: CAN Bus" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" diff --git a/manual/se/tb26.yaml b/manual/se/tb26.yaml new file mode 100644 index 0000000..52f43a6 --- /dev/null +++ b/manual/se/tb26.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB26 + format: "Manual Test Definition 1.0" + description: "TB26: CAN Bus" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" diff --git a/manual/se/tb27.yaml b/manual/se/tb27.yaml new file mode 100644 index 0000000..64228c2 --- /dev/null +++ b/manual/se/tb27.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB27 + format: "Manual Test Definition 1.0" + description: "TB27: CAN Bus" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" diff --git a/manual/se/tb28.yaml b/manual/se/tb28.yaml new file mode 100644 index 0000000..1d07732 --- /dev/null +++ b/manual/se/tb28.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB28 + format: "Manual Test Definition 1.0" + description: "TB28: UART loopback" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tb29.yaml b/manual/se/tb29.yaml new file mode 100644 index 0000000..b87c330 --- /dev/null +++ b/manual/se/tb29.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB29 + format: "Manual Test Definition 1.0" + description: "TB29: UART Loopback" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tb30.yaml b/manual/se/tb30.yaml new file mode 100644 index 0000000..2c4d1cd --- /dev/null +++ b/manual/se/tb30.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB30 + format: "Manual Test Definition 1.0" + description: "TB30: UART Loopback" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tb31.yaml b/manual/se/tb31.yaml new file mode 100644 index 0000000..934637b --- /dev/null +++ b/manual/se/tb31.yaml @@ -0,0 +1,28 @@ +metadata: + name: TB31 + format: "Manual Test Definition 1.0" + description: "TB31: Watchdog" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "TODO: copy wd-test*.deb from lces2 build to soca9 board" + + - " " + - "wdt_driver_test 5 4 1 # this should never reboot, CTRL-C to exit after about 1 min" + - "wdt_driver_test 5 6 0 # this should reboot after 5 secs" + - "wdt_driver_test 5 6 1 # this should reboot after 5 secs" + + expected: + - "reboots happen only when expected" + diff --git a/manual/se/tb32.yaml b/manual/se/tb32.yaml new file mode 100644 index 0000000..a968fbe --- /dev/null +++ b/manual/se/tb32.yaml @@ -0,0 +1,50 @@ +metadata: + name: TB32 + format: "Manual Test Definition 1.0" + description: "TB32: MTD flash" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "num=0 # for NAND" + - "num=2 # for NOR" + - "#lces2: ok" + - "num=9" + - " " + - "dev=/dev/mtd${num}" + - "blk=/dev/mtdblock${num}" + - "mnt=/mnt/jffs2" + - "tmp=/tmp/file.dat" + - " " + - "flash_erase -j ${dev} 0 0" + - "# Create a folder in which flash partition will be mounted:" + - "mkdir ${mnt}" + - "# Mount NOR Flash jffs2 partition" + - "mount -t jffs2 ${blk} ${mnt}" + - "cd ${mnt}" + - "dd if=/dev/urandom of=${tmp} bs=1K count=512" + - "md5sum ${tmp}" + - "cp ${tmp} ${mnt}" + - "sync" + - "cd" + - "umount ${mnt}" + - "reboot" + - "# set env vars from above" + - "ls ${mnt}" + - "mount -t jffs2 ${blk} ${mnt}" + - "md5sum ${mnt}/file.dat" + + expected: + - "no unpexpected errors reported" + - "md5sums match" diff --git a/manual/se/tb33.yaml b/manual/se/tb33.yaml new file mode 100644 index 0000000..de918af --- /dev/null +++ b/manual/se/tb33.yaml @@ -0,0 +1,25 @@ +metadata: + name: TB33 + format: "Manual Test Definition 1.0" + description: "TB33: MTD iozone" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "cd ${mnt}" + - "iozone -e -s 40M" + - "cd" + - "umount ${mnt}" + + expected: + - "iozone completes without errors" diff --git a/manual/se/tb34.yaml b/manual/se/tb34.yaml new file mode 100644 index 0000000..2ee67c4 --- /dev/null +++ b/manual/se/tb34.yaml @@ -0,0 +1,38 @@ +metadata: + name: TB34 + format: "Manual Test Definition 1.0" + description: "TB34: ubiattach" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "soca9:" + - "dev=/dev/mtd0" + - "mib=480" + - "#lces2:" + - "dev=/dev/mtd1" + - "mib=237" + - " " + - "mnt=/mnt/ubifs" + - "ubiformat -y ${dev}" + - " " + - "# Attach MTD device:" + - "ubiattach -p ${dev}" + - "# Create an 485MiB volume on UBI dev. 0:" + - "ubimkvol /dev/ubi0 -N ubifs_vol -s ${mib}MiB" + - "mkdir -p ${mnt}" + - "# Mount partition:" + - "mount -t ubifs /dev/ubi0_0 ${mnt}" + + expected: + - "ubi partition mounted" diff --git a/manual/se/tb35.yaml b/manual/se/tb35.yaml new file mode 100644 index 0000000..e98d401 --- /dev/null +++ b/manual/se/tb35.yaml @@ -0,0 +1,25 @@ +metadata: + name: TB35 + format: "Manual Test Definition 1.0" + description: "TB35: " + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "# run TB34 first" + - "cd ${mnt}" + - "iozone -e -s 40M" + - "cd ; umount ${mnt}" + + expected: + - "iozone completes without errors" diff --git a/manual/se/tb36.yaml b/manual/se/tb36.yaml new file mode 100644 index 0000000..6ac0868 --- /dev/null +++ b/manual/se/tb36.yaml @@ -0,0 +1,33 @@ +metadata: + name: TB36 + format: "Manual Test Definition 1.0" + description: "TB36: dmatest" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "channels=(0 1 2 3 4 5)" + - "modprobe dmatest" + - "#" + - "#lces2: ok" + - "channels=(2 3 4 5 6 7)" + - "#" + - "echo > /sys/module/dmatest/parameters/channel" + - "echo 2000 > /sys/module/dmatest/parameters/timeout" + - "echo 1000 > /sys/module/dmatest/parameters/iterations" + - "echo 1 > /sys/module/dmatest/parameters/run" + - "#" + - "for channel in ${channels[@]}; do echo dma0chan${channel} > /sys/module/dmatest/parameters/channel; echo 1 > /sys/module/dmatest/parameters/run ; sleep 5 ; done" + + expected: + - "no errors reported" diff --git a/manual/se/tb37.yaml b/manual/se/tb37.yaml new file mode 100644 index 0000000..e5483b0 --- /dev/null +++ b/manual/se/tb37.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB37 + format: "Manual Test Definition 1.0" + description: "TB37: Read/Write I2C EEPROM" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Run tc22" + + expected: + - "Same results as tc22" diff --git a/manual/se/tb38.yaml b/manual/se/tb38.yaml new file mode 100644 index 0000000..d0643dc --- /dev/null +++ b/manual/se/tb38.yaml @@ -0,0 +1,22 @@ +metadata: + name: TB38 + format: "Manual Test Definition 1.0" + description: "TB38: temperature sensor" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "cat /sys/class/hwmon/hwmon0/temp1_input" + + expected: + - "value read from the temperature input" diff --git a/manual/se/tb40.yaml b/manual/se/tb40.yaml new file mode 100644 index 0000000..43510db --- /dev/null +++ b/manual/se/tb40.yaml @@ -0,0 +1,23 @@ +metadata: + name: TB40 + format: "Manual Test Definition 1.0" + description: "TB40: RS485" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" + diff --git a/manual/se/tb41.yaml b/manual/se/tb41.yaml new file mode 100644 index 0000000..691d8fb --- /dev/null +++ b/manual/se/tb41.yaml @@ -0,0 +1,23 @@ +metadata: + name: TB41 + format: "Manual Test Definition 1.0" + description: "TB41: RS485" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" + diff --git a/manual/se/tc1.yaml b/manual/se/tc1.yaml new file mode 100644 index 0000000..38478e7 --- /dev/null +++ b/manual/se/tc1.yaml @@ -0,0 +1,23 @@ +metadata: + name: TC1 + format: "Manual Test Definition 1.0" + description: "TC1: Flash SD cards from the CI binaries" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Download the binaries from the release candidate CI snapshot" + - "Flash them to SD card" + + expected: + - "The board should boot normally and the user is able to log in" diff --git a/manual/se/tc16.yaml b/manual/se/tc16.yaml new file mode 100644 index 0000000..f4ead1f --- /dev/null +++ b/manual/se/tc16.yaml @@ -0,0 +1,68 @@ +metadata: + name: TC16 + format: "Manual Test Definition 1.0" + description: "TC16: Dual Core CMP" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "cat /proc/cpuinfo" + + expected: + - "# soca9" + - "root@snarc-soca9:/data/linux_scripts/linux# cat /proc/cpuinfo" + - "processor : 0" + - "model name : ARMv7 Processor rev 0 (v7l)" + - "BogoMIPS : 200.00" + - "Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpd32" + - "CPU implementer : 0x41" + - "CPU architecture: 7" + - "CPU variant : 0x3" + - "CPU part : 0xc09" + - "CPU revision : 0" + - "processor : 1" + - "model name : ARMv7 Processor rev 0 (v7l)" + - "BogoMIPS : 200.00" + - "Features : half thumb fastmult vfp edsp neon vfpv3 tls vfpd32" + - "CPU implementer : 0x41" + - "CPU architecture: 7" + - "CPU variant : 0x3" + - "CPU part : 0xc09" + - "CPU revision : 0" + - "Hardware : Altera SOCFPGA" + - "Revision : 0000" + - "Serial : 0000000000000000" + - " " + - "# lces2" + - "root@rzn1-snarc:/data/linux_scripts/linux# cat /proc/cpuinfo" + - "processor : 0" + - "model name : ARMv7 Processor rev 5 (v7l)" + - "BogoMIPS : 12.50" + - "Features : half thumb fastmult vfp edsp thumbee vfpv3 vfpv3d16 tls vfpv4 idiva idivt lpae evtstrm" + - "CPU implementer : 0x41" + - "CPU architecture: 7" + - "CPU variant : 0x0" + - "CPU part : 0xc07" + - "CPU revision : 5" + - "processor : 1" + - "model name : ARMv7 Processor rev 5 (v7l)" + - "BogoMIPS : 12.50" + - "Features : half thumb fastmult vfp edsp thumbee vfpv3 vfpv3d16 tls vfpv4 idiva idivt lpae evtstrm" + - "CPU implementer : 0x41" + - "CPU architecture: 7" + - "CPU variant : 0x0" + - "CPU part : 0xc07" + - "CPU revision : 5" + - "Hardware : Renesas RZ/N1 (DT)" + - "Revision : 0000" + - "Serial : LCES2-0x0000000000000000" diff --git a/manual/se/tc17.yaml b/manual/se/tc17.yaml new file mode 100644 index 0000000..7592148 --- /dev/null +++ b/manual/se/tc17.yaml @@ -0,0 +1,26 @@ +metadata: + name: TC17 + format: "Manual Test Definition 1.0" + description: "TC17: CPU Core Clock" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "# soca9: skip" + - "# lces2: ok" + - " " + - "SCP a clone of the test scripts repo to the board" + - "bash ~/test-scripts/test-cpu-freq.sh" + + expected: + - "Test reports pass" diff --git a/manual/se/tc18.yaml b/manual/se/tc18.yaml new file mode 100644 index 0000000..368ba25 --- /dev/null +++ b/manual/se/tc18.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC18 + format: "Manual Test Definition 1.0" + description: "TC18: UDL Timer" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "sleep 10" + + expected: + - "Sleep happens for 10 seconds, timed with a stopwatch" diff --git a/manual/se/tc19.yaml b/manual/se/tc19.yaml new file mode 100644 index 0000000..29a68ea --- /dev/null +++ b/manual/se/tc19.yaml @@ -0,0 +1,37 @@ +metadata: + name: TC19 + format: "Manual Test Definition 1.0" + description: "TC19: Real Time Clock" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - '# soca9: skip' + - '# lces2: ok' + - ' ' + - '# example of setting hwclock' + - '# hwclock --set --date="2015-12-31 23:59:55" --localtime' + - ' ' + - '# Run this command sequence, the watch the time tick over from from 2015 to 2016' + - ' ' + - 'hwclock --set --date="2015-12-31 23:59:55" --localtime ; while [ true ]; do hwclock; sleep 10; done' + - 'reboot' + - '# check date and time after reboot' + - 'hwclock' + - 'date' + - ' ' + - '# Set the hwclock back to match the system time' + - 'hwclock -w' + + expected: + - 'clock is set to the specified values and overflows correctly' diff --git a/manual/se/tc2.yaml b/manual/se/tc2.yaml new file mode 100644 index 0000000..b701ebd --- /dev/null +++ b/manual/se/tc2.yaml @@ -0,0 +1,23 @@ +metadata: + name: TC2 + format: "Manual Test Definition 1.0" + description: "TC2: boot SD card with release candidate images" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Boot the board from the SD card using the 'linux_sd' command in U-Boot" + - "Log in at the prompt" + + expected: + - "The board should boot normally and the user is able to log in" diff --git a/manual/se/tc20.yaml b/manual/se/tc20.yaml new file mode 100644 index 0000000..807c11d --- /dev/null +++ b/manual/se/tc20.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC20 + format: "Manual Test Definition 1.0" + description: "TC20: UART Loopback" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tc21.yaml b/manual/se/tc21.yaml new file mode 100644 index 0000000..9e116f9 --- /dev/null +++ b/manual/se/tc21.yaml @@ -0,0 +1,27 @@ +metadata: + name: TC21 + format: "Manual Test Definition 1.0" + description: "TC21: I2C detect" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "dev=0" + - "#lces2: ok" + - "dev=1" + - " " + - "i2cdetect -y -r ${dev}" + + expected: + - "I2C device detected" diff --git a/manual/se/tc22.yaml b/manual/se/tc22.yaml new file mode 100644 index 0000000..6dd948f --- /dev/null +++ b/manual/se/tc22.yaml @@ -0,0 +1,32 @@ +metadata: + name: TC22 + format: "Manual Test Definition 1.0" + description: "TC22: Read/Write I2C EEPROM" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "# soca9: ok" + - "EEPROM=/sys/bus/i2c/devices/0-0050/eeprom" + - "# lces2: ok" + - "EEPROM=/sys/bus/i2c/devices/1-0050/eeprom" + - " " + - "dd if=/dev/urandom of=${TMPFILE} bs=1 count=64" + - "dd if=${TMPFILE} of=${EEPROM}" + - "dd if=${EEPROM} of=${TMPFILE}.read bs=1 count=64" + - "cmp ${TMPFILE} ${TMPFILE}.read" + - "if [ $? -eq 0 ]; then echo pass; else echo fail; fi" + - "time cat ${EEPROM} | od -x" + + expected: + - "pass is displayed on the terminal" diff --git a/manual/se/tc23.yaml b/manual/se/tc23.yaml new file mode 100644 index 0000000..dfa9506 --- /dev/null +++ b/manual/se/tc23.yaml @@ -0,0 +1,28 @@ +metadata: + name: TC23 + format: "Manual Test Definition 1.0" + description: "TC23: I2C Error Handling" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "dev=0" + - "#lces2: ok" + - "dev=1" + - " " + - "device_exists /dev/i2c-${dev}" + - "i2cset -y ${dev} 0x60 0x00" + + expected: + - "Error: Write failed" diff --git a/manual/se/tc25.yaml b/manual/se/tc25.yaml new file mode 100644 index 0000000..360af5b --- /dev/null +++ b/manual/se/tc25.yaml @@ -0,0 +1,49 @@ +metadata: + name: TC25 + format: "Manual Test Definition 1.0" + description: "TC25: NAND Controller" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "NAND_MTD=/dev/mtd0" + - "#lces2: ok" + - "NAND_MTD=/dev/mtd1" + - " " + - "USB_DEV=/dev/sda1" + - " " + - "device_exists $NAND_MTD" + - "device_exists $USB_DEV" + - " " + - "# This might fail if there are bad blocks on the NAND" + - "#dd if=/dev/urandom of=/tmp/random bs=1M count=10 && time flashcp -v /tmp/random $NAND_MTD" + - " " + - "flash_erase $NAND_MTD 0 0" + - " " + - "# This is a more reliable/realistic test because it skips bad blocks" + - "dd if=/dev/urandom of=/tmp/random bs=1M count=10 && time nandwrite $NAND_MTD /tmp/random" + - " " + - "# mount the USB stick first" + - "mnt=/mnt/usb" + - "mkdir -p ${mnt}" + - "mount ${USB_DEV} ${mnt}" + - " " + - "nanddump -l 10485760 ${NAND_MTD} > ${mnt}/nand.bin" + - " " + - "ls -al /tmp/random ${mnt}/nand.bin" + - "md5sum /tmp/random ${mnt}/nand.bin" + - "umount ${mnt}" + + expected: + - "md5sums match" diff --git a/manual/se/tc26.yaml b/manual/se/tc26.yaml new file mode 100644 index 0000000..936cc07 --- /dev/null +++ b/manual/se/tc26.yaml @@ -0,0 +1,45 @@ +metadata: + name: TC26 + format: "Manual Test Definition 1.0" + description: "TC26: NAND MTD Read/Write" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "PART=0" + - "#lces2: ok" + - "PART=1" + - "sumfile=~/tc26.md5" + - "rm ${sumfile}*" + - " " + - "./test-mtd-write.sh ${PART} 512 | tail -1 | cut -d \" \" -f 1 | tee ${sumfile}" + - "# note checksum output" + - "reboot" + - " " + - "#soca9:" + - "PART=0" + - "#lces2:" + - "PART=1" + - " " + - " " + - "sumfile=~/tc26.md5" + - "./test-mtd-read.sh ${PART} | tail -1 | cut -d \" \" -f 1 | tee ${sumfile}.read" + - "# verify checksum matches one from the write test" + - " " + - "cat ${sumfile}*" + - "cmp ${sumfile}*" + - "if [ $? -eq 0 ]; then echo pass; else echo fail; fi" + + expected: + - "Test echos pass" diff --git a/manual/se/tc27.yaml b/manual/se/tc27.yaml new file mode 100644 index 0000000..d7580b8 --- /dev/null +++ b/manual/se/tc27.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC27 + format: "Manual Test Definition 1.0" + description: "TC27: USB Mass Storage" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tc28.yaml b/manual/se/tc28.yaml new file mode 100644 index 0000000..233e597 --- /dev/null +++ b/manual/se/tc28.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC28 + format: "Manual Test Definition 1.0" + description: "TC28: USB Mass Storage Bonnie++ test" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tc29.yaml b/manual/se/tc29.yaml new file mode 100644 index 0000000..671765e --- /dev/null +++ b/manual/se/tc29.yaml @@ -0,0 +1,42 @@ +metadata: + name: TC29 + format: "Manual Test Definition 1.0" + description: "TC29: USB RNDIS" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Connect a USB cable from J9 USB OTG on the board to a host PC" + - " " + - "#soca9: skip" + - "#lces2: ok" + - " " + - "# From host machine:" + - "script -a /host-00n.log" + - "hostif=usb0" + - "hostif=enp0s29u1u2u4u3 # on 'x220' laptop" + - "hostif=enp0s20f0u5u2u2 # on 'bld' desktop machine" + - "hostif=enp0s20f0u3u2u2 # on 'bld' desktop machine with LCES2 board 2" + - "targetip=10.0.0.35 # original test used 192.168.1.35, but that clashes with my network setup" + - " " + - "sudo ifconfig ${hostif} down" + - "sudo ifconfig ${hostif} ${targetip} up" + - "sudo ifconfig ${hostif}" + - " " + - "for n in 1 1 1500; do" + - " echo \"n: $n\"" + - " ping -c 5 -s $n -I ${hostif} ${targetip}" + - "done" + + expected: + - "ping returns without failures" diff --git a/manual/se/tc3.yaml b/manual/se/tc3.yaml new file mode 100644 index 0000000..0a4a27f --- /dev/null +++ b/manual/se/tc3.yaml @@ -0,0 +1,23 @@ +metadata: + name: TC3 + format: "Manual Test Definition 1.0" + description: "TC3: ce_count" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "ce_count is not available" + - "This test should be skipped" + + expected: + - "skip" diff --git a/manual/se/tc30.yaml b/manual/se/tc30.yaml new file mode 100644 index 0000000..a8f95bb --- /dev/null +++ b/manual/se/tc30.yaml @@ -0,0 +1,45 @@ +metadata: + name: TC30 + format: "Manual Test Definition 1.0" + description: "TC30: USB RNDIS fping" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: skip" + - "#lces2: ok" + - " " + - "NR_PKTS=10" + - " " + - "# run tc.29, then from host machine:" + - "# large:" + - "start=64501" + - "end=65000" + - "for (( bytes=${start}; bytes<=${end}; bytes++ )); do" + - " let iters_left=${end}-${bytes}" + - " echo \"bytes=${bytes} (${iters_left} iterations left)\"" + - " fping $targetip -c $NR_PKTS -b ${bytes} -o" + - "done" + - " " + - "# small:" + - "start=1" + - "end=15" + - "for (( bytes=${start}; bytes<=${end}; bytes++ )); do" + - " echo bytes=${bytes}" + - " fping $targetip -c $NR_PKTS -b ${bytes} -o" + - "done" + - " " + - "sudo ifconfig ${hostif} down" + + expected: + - "fping returns without failures" diff --git a/manual/se/tc31.yaml b/manual/se/tc31.yaml new file mode 100644 index 0000000..7306c86 --- /dev/null +++ b/manual/se/tc31.yaml @@ -0,0 +1,27 @@ +metadata: + name: TC31 + format: "Manual Test Definition 1.0" + description: "TC31: QSPI" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9:" + - "QSPI_MTD=/dev/mtd2" + - "#lces2: ok" + - "QSPI_MTD=/dev/mtd9" + - " " + - "dd if=/dev/urandom of=/tmp/random bs=1M count=1 && time flashcp -v /tmp/random $QSPI_MTD" + + expected: + - "flashcp completes without errors" diff --git a/manual/se/tc32.yaml b/manual/se/tc32.yaml new file mode 100644 index 0000000..e922386 --- /dev/null +++ b/manual/se/tc32.yaml @@ -0,0 +1,24 @@ +metadata: + name: TC32 + format: "Manual Test Definition 1.0" + description: "TC32: QSPI mtd_debug" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: skip" + - "#lces2: ok" + - "time mtd_debug read $QSPI_MTD 0 0x830000 /tmp/a" + + expected: + - " " diff --git a/manual/se/tc33.yaml b/manual/se/tc33.yaml new file mode 100644 index 0000000..23bda11 --- /dev/null +++ b/manual/se/tc33.yaml @@ -0,0 +1,37 @@ +metadata: + name: TC33 + format: "Manual Test Definition 1.0" + description: "TC33: QSPI MTD read/write" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "dev=2" + - "#lces2: ok" + - "dev=9" + - " " + - "sumfile=~/tc26.md5" + - " " + - "./test-mtd-write.sh ${dev} 128 | tail -1 | cut -d \" \" -f 1 | tee ${sumfile}.write" + - " " + - "reboot" + - "sumfile=~/tc26.md5" + - "./test-mtd-read.sh ${dev} | tail -1 | cut -d \" \" -f 1 | tee ${sumfile}.read" + - " " + - "cat ${sumfile}.*" + - "cmp ${sumfile}.*" + - "if [ $? -eq 0 ]; then echo pass; else echo fail; fi" + + expected: + - "The checksum matches, pass is echoed to the terminal" diff --git a/manual/se/tc34.yaml b/manual/se/tc34.yaml new file mode 100644 index 0000000..b74d563 --- /dev/null +++ b/manual/se/tc34.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC34 + format: "Manual Test Definition 1.0" + description: "TC34: USB Ethernet adapter" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Test script got1Mnew not available" + + expected: + - "skip" diff --git a/manual/se/tc35.yaml b/manual/se/tc35.yaml new file mode 100644 index 0000000..c118ca9 --- /dev/null +++ b/manual/se/tc35.yaml @@ -0,0 +1,28 @@ +metadata: + name: TC35 + format: "Manual Test Definition 1.0" + description: "TC35: Large ping" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "targetip=192.168.1.71" + - "#lces2: ok" + - "targetip=192.168.1.108" + - " " + - "#On the development host:" + - "ping -c 500 -s 32768 ${targetip}" + + expected: + - "ping returns without errors" diff --git a/manual/se/tc36.yaml b/manual/se/tc36.yaml new file mode 100644 index 0000000..9a76b3b --- /dev/null +++ b/manual/se/tc36.yaml @@ -0,0 +1,91 @@ +metadata: + name: TC36 + format: "Manual Test Definition 1.0" + description: "TC36: GPIO LED Use Case 1" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "# soca9: ok" + - "d1grn=1952 # D1 green" + - "d1red=1953 # D1 red" + - "d3grn=1954 # D3 green" + - "d3red=1955 # D3 red" + - " " + - "function led_enable()" + - "{" + - " local led=$1" + - " cd /sys/class/gpio/" + - " echo ${led} > export" + - " echo \"out\" > gpio${led}/direction" + - "}" + - " " + - "function led_set()" + - "{" + - " local led=$1" + - " local value=$2" + - " echo $value > gpio${led}/value" + - " sleep 0.5" + - "}" + - " " + - "function led_disable()" + - "{" + - " local led=$1" + - " cd /sys/class/gpio/" + - " echo ${led} > unexport" + - "}" + - " " + - "led_enable ${d1grn}" + - "led_enable ${d1red}" + - "led_enable ${d3grn}" + - "led_enable ${d3red}" + - " " + - "# D1 green/orange/red" + - "led_set ${d1grn} 255" + - "led_set ${d1red} 255" + - "led_set ${d1grn} 0" + - "led_set ${d1red} 0" + - " " + - "# D3 green/orange/red" + - "led_set ${d3grn} 255" + - "led_set ${d3red} 255" + - "led_set ${d3grn} 0" + - "led_set ${d3red} 0" + - " " + - "led_disable ${d1grn}" + - "led_disable ${d1red}" + - "led_disable ${d3grn}" + - "led_disable ${d3red}" + - " " + - "#lces2: ok" + - "# Sumo & Warrior:" + - " " + - "function led_test()" + - "{" + - " local led=$1" + - " echo none > $led/trigger" + - " echo 255 > $led/brightness" + - " sleep 1" + - " echo 0 > $led/brightness" + - " sleep 1" + - " echo 255 > $led/brightness" + - " sleep 1" + - " echo 0 > $led/brightness" + - "}" + - "led_test /sys/class/leds/pl_gpio13 # LED D3 (Red LED)" + - "led_test /sys/class/leds/pl_gpio14 # LED D3 (Green LED)" + - "led_test /sys/class/leds/pl_gpio17 # LED D1 (Green LED)" + - "led_test /sys/class/leds/pl_gpio18 # LED D1 (Red LED)" + + expected: + - "LEDs light up with correct colours" diff --git a/manual/se/tc37.yaml b/manual/se/tc37.yaml new file mode 100644 index 0000000..f07a69a --- /dev/null +++ b/manual/se/tc37.yaml @@ -0,0 +1,44 @@ +metadata: + name: TC37 + format: "Manual Test Definition 1.0" + description: "TC37: GPIO input" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "# Sumo 4.9" + - "sw3=384" + - "sw4=385" + - "# Warrior 4.19" + - "sw3=1920" + - "sw4=1921" + - " " + - "#lces2: ok" + - "sw3=461" + - "# sw4 is not routed as a GPIO like this" + - " " + - "# buttons on SoCA9 are SW3 and SW4" + - "sw=${sw3}" + - "# or" + - "sw=${sw4}" + - " " + - "echo ${sw} > /sys/class/gpio/export" + - "echo in > /sys/class/gpio/gpio${sw}/direction" + - "cat /sys/class/gpio/gpio${sw}/value" + - " " + - "echo 1 > /sys/class/gpio/gpio${sw}/active_low" + - "cat /sys/class/gpio/gpio${sw}/value" + + expected: + - "The GPIO value read correctly when the button is pressed or not" diff --git a/manual/se/tc38.yaml b/manual/se/tc38.yaml new file mode 100644 index 0000000..0188882 --- /dev/null +++ b/manual/se/tc38.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC38 + format: "Manual Test Definition 1.0" + description: "TC38: GPIO Input" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "TC37 runs the tests needed for this testcase" + + expected: + - "Same results as TC37" diff --git a/manual/se/tc39.yaml b/manual/se/tc39.yaml new file mode 100644 index 0000000..11297f2 --- /dev/null +++ b/manual/se/tc39.yaml @@ -0,0 +1,34 @@ +metadata: + name: TC39 + format: "Manual Test Definition 1.0" + description: "TC30: Watchdog timer" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "watchdog -t 20 -T 30 /dev/watchdog" + - "ps -ef | grep watch | grep -v grep" + - "# check the watchdogs are created" + - "# Example output:" + - "# root@rzn1-snarc:~# ps -ef | grep watch | grep -v grep" + - "# root 31 2 0 16:44 ? 00:00:00 [watchdogd]" + - "# root 330 1 0 16:51 ? 00:00:00 watchdog -t 20 -T 30 /dev/watchdog" + - " " + - "# Kill the program, check it goes away, but the [watchdogd] entry stays" + - "process=$(ps -ef | grep watch | grep -v \"grep\" | tail -1 | awk '{print $2}')" + - "echo ${process}" + - "kill ${process}" + - "ps -ef | grep watch | grep -v grep" + + expected: + - "Watchdog processes are started and terminated" diff --git a/manual/se/tc40.yaml b/manual/se/tc40.yaml new file mode 100644 index 0000000..3a66301 --- /dev/null +++ b/manual/se/tc40.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC40 + format: "Manual Test Definition 1.0" + description: "TC40: Watchdog" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Scripts not available" + + expected: + - "skip" diff --git a/manual/se/tc41.yaml b/manual/se/tc41.yaml new file mode 100644 index 0000000..0b0d312 --- /dev/null +++ b/manual/se/tc41.yaml @@ -0,0 +1,37 @@ +metadata: + name: TC41 + format: "Manual Test Definition 1.0" + description: "TC41: DHCP IP Address" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "#soca9: ok" + - "ipaddr=192.168.1.171" + - "dev=eth1 # eth0 incdicates freja dtb" + - "#lces2: ok" + - "dev=eth1" + - "ipaddr=192.168.1.170" + - " " + - "ifconfig ${dev}" + - "ifconfig ${dev} down" + - "ifconfig ${dev} ${ipaddr} up" + - "ifconfig ${dev}" + - " " + - "dhclient -r ${dev}" + - "ifconfig ${dev}" + - " " + - "ifconfig ${dev} down" + + expected: + - "IP addresses are assigned" diff --git a/manual/se/tc42.yaml b/manual/se/tc42.yaml new file mode 100644 index 0000000..4953487 --- /dev/null +++ b/manual/se/tc42.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC42 + format: "Manual Test Definition 1.0" + description: "TC42: memtester" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Runs in LAVA" + + expected: + - "skip" diff --git a/manual/se/tc43.yaml b/manual/se/tc43.yaml new file mode 100644 index 0000000..07608b7 --- /dev/null +++ b/manual/se/tc43.yaml @@ -0,0 +1,22 @@ +metadata: + name: TC43 + format: "Manual Test Definition 1.0" + description: "TC43: CAN Bus" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - "Hardware not available" + + expected: + - "skip" diff --git a/manual/se/tc44.yaml b/manual/se/tc44.yaml new file mode 100644 index 0000000..86d1176 --- /dev/null +++ b/manual/se/tc44.yaml @@ -0,0 +1,99 @@ +metadata: + name: TC44 + format: "Manual Test Definition 1.0" + description: "TC44: Password Change" + maintainer: + - ryan.harkin@linaro.org + os: + - openembedded + scope: + - functional + devices: + - lces2 + - soca9 + environment: + - manual-test + +run: + steps: + - 'passwd root' + - 'P@ssword-2' + - ' ' + - 'useradd passtest' + - 'passwd passtest << EOF' + - 'passWd1!' + - 'passWd1!' + - 'passWd1!' + - 'EOF' + - ' ' + - 'cp -r ~/test-scripts/ /home/passtest/' + - 'logout' + - ' ' + - '# log in as user passtest' + - '# Run "passwd" with this sequence of passwords:' + - 'newpassword="passWd1!"' + - 'passwd << EOF' + - '${newpassword}' + - '${newpassword}' + - '${newpassword}' + - '${newpassword}' + - '${newpassword}' + - '${newpassword}' + - '${newpassword}' + - 'EOF' + - ' ' + - '# Look for this error, it is expected and means the test has passed:' + - '"passwd: password unchanged"' + - ' ' + - '# List of newpasswords' + - '# Look for success:' + - '# "password updated successfully"' + - 'newpassword="passWd1!"' + - 'oldpassword=${newpassword}; newpassword="u7F8A:e="; ./test-password-change.sh "${oldpassword}" "${newpassword}"' + - 'oldpassword=${newpassword}; newpassword="6rY9bN~)"; ./test-password-change.sh "${oldpassword}" "${newpassword}"' + - 'oldpassword=${newpassword}; newpassword="!qIS2{h3"; ./test-password-change.sh "${oldpassword}" "${newpassword}"' + - 'oldpassword=${newpassword}; newpassword="])Qoh24I"; ./test-password-change.sh "${oldpassword}" "${newpassword}"' + - 'oldpassword=${newpassword}; newpassword="66%U-Hpa"; ./test-password-change.sh "${oldpassword}" "${newpassword}"' + - 'oldpassword=${newpassword}; newpassword="33uCl/D@"; ./test-password-change.sh "${oldpassword}" "${newpassword}"' + - 'oldpassword=${newpassword}; newpassword="y0T8> ${plan} + echo " repository: https://git.linaro.org/landing-teams/working/schneider/test-definitions.git" >> ${plan} + echo " branch: linaro" >> ${plan} +done + +################################################################################ +# generate se-tc.yaml +# all manual/se/tc*.yaml files +################################################################################ +plan=plans/se-tc.yaml +cp plans/se-template.yaml ${plan} + +sed -e "s/se-template/se-tc/g" -i ${plan} +sed -e "s/Scheider Electric template/Scheider Electric TC Test Plan/g" -i ${plan} +# TODO - describe what the TC test plan is" + +testcases=($(ls -v manual/se/tc*.yaml)) +for testcase in "${testcases[@]}" ; do + echo " - path: ${testcase}" >> ${plan} + echo " repository: https://git.linaro.org/landing-teams/working/schneider/test-definitions.git" >> ${plan} + echo " branch: linaro" >> ${plan} +done + +################################################################################ +# generate se-others.yaml +# all manual/se/*.yaml files not included in se-tb and te-tc plans +################################################################################ +plan=plans/se-others.yaml +cp plans/se-template.yaml ${plan} + +sed -e "s/se-template/se-others/g" -i ${plan} +sed -e "s/Scheider Electric template/Scheider Electric Misc Manual Test Plan/g" -i ${plan} +# TODO - describe what this test plan is" + +testcases=($(ls -v manual/se/*.yaml | grep -v t[bc][0-9])) +for testcase in "${testcases[@]}" ; do + echo " - path: ${testcase}" >> ${plan} + echo " repository: https://git.linaro.org/landing-teams/working/schneider/test-definitions.git" >> ${plan} + echo " branch: linaro" >> ${plan} +done + +################################################################################ +# generate se-all.yaml +# everything in se-auto.yaml, and all yamls in manual/se +################################################################################ +plan=plans/se-all-tests.yaml +cp plans/se-auto.yaml ${plan} + +sed -e "s/se-auto/se-all-tests/g" -i ${plan} +sed -e "s/Scheider Electric Automated Test Plan/Scheider Electric Test Plan describing all manual and automated tests performed when making a release/g" -i ${plan} +# TODO - describe what this test plan is" + +echo " manual:" >> ${plan} +testcases=($(ls -v manual/se/*.yaml | grep -v tb[0-9]-j | sort -V)) + +for testcase in "${testcases[@]}" ; do + echo " - path: ${testcase}" >> ${plan} + echo " repository: https://git.linaro.org/landing-teams/working/schneider/test-definitions.git" >> ${plan} + echo " branch: linaro" >> ${plan} +done + + +################################################################################ +# Generate the HTML Test Plan +################################################################################ +pushd plans +plan=se-all-tests +sed -e "s/Metadata/Schneider Electric Test Plan/g" -i templates/testplan_v2.html +./testplan2html.py -f ${plan}.yaml -i -s --pdf output/${plan}.pdf +popd -- cgit v1.2.3