From ec4faa26c9639a8bb6a5b025dc94de57ac874d78 Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Thu, 27 Aug 2020 10:39:05 +0200 Subject: [PATCH 01/16] SPEC-3550: handle package with service name different than their filename Some package has their service name different than their filename. This patch handle this situation Bug-AGL: SPEC-3550 Change-Id: I99c102f411ce5a0636fa14528cd2890694d986c6 Signed-off-by: Corentin LABBE --- common/scripts/application-lifecycle.sh | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index bf9d575..ee3d790 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -83,6 +83,7 @@ done inspect_wgt() { wgtfile=$1 + WGTNAME=$2 export SERVICE_PLATFORM=0 export SERVICE_USER=0 @@ -120,6 +121,15 @@ inspect_wgt() { export APPLICATION_USER=1 # no other type known (yet) fi + # the file naming convention is servicename.wgt + # but some didnt respect it + export WGTSERVICENAME=$(grep '' config.xml | cut -d'>' -f2 | cut -d'<' -f1) + if [ -z "$WGTSERVICENAME" ];then + echo "WARN: failed to find name in config.xml, fallback to filename" + export WGTSERVICENAME="$WGTNAME" + else + echo "DEBUG: detected service name as $WGTSERVICENAME" + fi else echo "DEBUG: fail to unzip" fi @@ -171,7 +181,7 @@ do_release_test() { fi echo "DEBUG: check presence of $WGTNAME" - NAMEID=$(grep id\\\":\\\"${WGTNAME}\" $LIST | cut -d\" -f4 | cut -d\\ -f1) + NAMEID=$(grep id\\\":\\\"${WGTSERVICENAME}\" $LIST | cut -d\" -f4 | cut -d\\ -f1) if [ ! -z "$NAMEID" ];then echo "DEBUG: $WGTNAME already installed as $NAMEID" # need to kill then deinstall @@ -216,7 +226,7 @@ do_release_test() { lava-test-case afm-util-install-$WGTNAMEF --result pass fi # message is like \"added\":\"mediaplayer@0.1\" - NAMEID=$(grep d\\\":\\\"${WGTNAME}\" $OUT | cut -d\" -f4 | cut -d\\ -f1) + NAMEID=$(grep d\\\":\\\"${WGTSERVICENAME}\" $OUT | cut -d\" -f4 | cut -d\\ -f1) if [ -z "$NAMEID" ];then echo "ERROR: Cannot get nameid" echo "DEBUG: ========== DUMPING output ==========" @@ -353,7 +363,7 @@ WGTNAMES=$(grep -o '[a-z-]*.wgt' index.html | sed 's,.wgt$,,' | sed 's,-debug$,, for WGTNAME in $WGTNAMES do if [ -e $WGTNAME.wgt ];then - inspect_wgt $WGTNAME.wgt + inspect_wgt $WGTNAME.wgt $WGTNAME do_release_test $WGTNAME $WGTNAME.wgt else echo "WARN: cannot find $WGTNAME.wgt" @@ -378,11 +388,11 @@ do echo "WARN: cannot find $WGTNAME.wgt" fi if [ -e $WGTNAME-debug.wgt ];then - inspect_wgt $WGTNAME-debug.wgt + inspect_wgt $WGTNAME-debug.wgt $WGTNAME do_release_test $WGTNAME $WGTNAME-debug.wgt fi if [ -e $WGTNAME-coverage.wgt ];then - inspect_wgt $WGTNAME-coverage.wgt + inspect_wgt $WGTNAME-coverage.wgt $WGTNAME echo "DEBUG: coverage not handled yet" fi done -- 2.16.6 From df2bdeb86d2aae337099db86b87de4c353592185 Mon Sep 17 00:00:00 2001 From: Jan-Simon Moeller Date: Wed, 9 Sep 2020 14:35:45 +0200 Subject: [PATCH 02/16] Add test definitions for pyagl We can now call pytest using the pyagl/tests module. These expose -k regular and -k hwrequired, thus create two caller scripts. Also create a sample testsuite entry using the regular variant with limited AGL_AVAILABLE_INTERFACES. Bug-AGL: SPEC-3572 Signed-off-by: Jan-Simon Moeller Change-Id: Ic6b977da959f946ca88348715d5249748c70f736 --- common/scripts/pyagl-hwrequired-lava.sh | 5 +++++ common/scripts/pyagl-regular-lava.sh | 7 +++++++ test-suites/short-smoke/pyagl-regular-oneshot.yaml | 14 ++++++++++++++ 3 files changed, 26 insertions(+) create mode 100755 common/scripts/pyagl-hwrequired-lava.sh create mode 100755 common/scripts/pyagl-regular-lava.sh create mode 100644 test-suites/short-smoke/pyagl-regular-oneshot.yaml diff --git a/common/scripts/pyagl-hwrequired-lava.sh b/common/scripts/pyagl-hwrequired-lava.sh new file mode 100755 index 0000000..8477b64 --- /dev/null +++ b/common/scripts/pyagl-hwrequired-lava.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +pytest --show-capture=no --color=no -k hwrequired /usr/lib/python?.?/site-packages/pyagl/tests/ -L + + diff --git a/common/scripts/pyagl-regular-lava.sh b/common/scripts/pyagl-regular-lava.sh new file mode 100755 index 0000000..db1799c --- /dev/null +++ b/common/scripts/pyagl-regular-lava.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# for now play safe and only expect ethernet +export AGL_AVAILABLE_INTERFACES="ethernet" + +pytest --color=no --show-capture=no -k regular /usr/lib/python?.?/site-packages/pyagl/tests/ -L + + diff --git a/test-suites/short-smoke/pyagl-regular-oneshot.yaml b/test-suites/short-smoke/pyagl-regular-oneshot.yaml new file mode 100644 index 0000000..0bc53fd --- /dev/null +++ b/test-suites/short-smoke/pyagl-regular-oneshot.yaml @@ -0,0 +1,14 @@ +# These tests are applicable if the board to be used has at least one CAN interface. + +metadata: + name: pyagl_regular_oneshot + format: "Lava-Test-Shell Test Definition 1.0" + description: "pyagl_regular_oneshot" + version: 1.0 + +run: + steps: + - echo "pyagl regular oneshot" + - lava-test-set start pyagl-regular-oneshot + - ./common/scripts/pyagl-regular-lava.sh + - lava-test-set stop -- 2.16.6 From 4619ed83a8906fd6700850d70bf99d58bc9776ab Mon Sep 17 00:00:00 2001 From: Jan-Simon Moeller Date: Wed, 9 Sep 2020 16:30:30 +0200 Subject: [PATCH 03/16] Add not hwrequired to regular script case Qemu by default has no hardware attached. Limit the run to not execut hardware-specific tests. Bug-AGL: SPEC-3572 Signed-off-by: Jan-Simon Moeller Change-Id: I3305d0c34737cf026989e2bde197d8ce3d96db19 --- common/scripts/pyagl-regular-lava.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/scripts/pyagl-regular-lava.sh b/common/scripts/pyagl-regular-lava.sh index db1799c..a64d9d8 100755 --- a/common/scripts/pyagl-regular-lava.sh +++ b/common/scripts/pyagl-regular-lava.sh @@ -2,6 +2,6 @@ # for now play safe and only expect ethernet export AGL_AVAILABLE_INTERFACES="ethernet" -pytest --color=no --show-capture=no -k regular /usr/lib/python?.?/site-packages/pyagl/tests/ -L +pytest --color=no --show-capture=no -k "regular and not hwrequired" /usr/lib/python?.?/site-packages/pyagl/tests/ -L -- 2.16.6 From 1718c39f29f71b99d38065686770548f8e4333ee Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Thu, 10 Sep 2020 14:37:20 +0200 Subject: [PATCH 04/16] SPEC-3550: name could be in uppercase In config.xml, name could be in uppercase, so let's use id which is lowercase. Change-Id: Ibc3e9e145692c7773f70a1308c7ff0de27e9f0bd Signed-off-by: Corentin LABBE --- common/scripts/application-lifecycle.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index ee3d790..2674530 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -123,7 +123,7 @@ inspect_wgt() { fi # the file naming convention is servicename.wgt # but some didnt respect it - export WGTSERVICENAME=$(grep '' config.xml | cut -d'>' -f2 | cut -d'<' -f1) + export WGTSERVICENAME=$(grep 'id=.*' config.xml | cut -d= -f2 | cut -d'"' -f2) if [ -z "$WGTSERVICENAME" ];then echo "WARN: failed to find name in config.xml, fallback to filename" export WGTSERVICENAME="$WGTNAME" -- 2.16.6 From 4a25de357684fbf3d0e280dc5697ac97d090ae6b Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Mon, 14 Sep 2020 10:12:28 +0200 Subject: [PATCH 05/16] SPEC-3550: fix parsing of id The id could be not the first element, and so the parsing is wrong. Change-Id: I325aac6de4733a166c7be8e3515b85e9edff4365 Bug-AGL: SPEC-3550 Signed-off-by: Corentin LABBE --- common/scripts/application-lifecycle.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index 2674530..b9b3328 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -123,7 +123,7 @@ inspect_wgt() { fi # the file naming convention is servicename.wgt # but some didnt respect it - export WGTSERVICENAME=$(grep 'id=.*' config.xml | cut -d= -f2 | cut -d'"' -f2) + export WGTSERVICENAME=$(grep 'id=.*' config.xml | sed 's,^.*id=,id=,' | cut -d= -f2 | cut -d'"' -f2) if [ -z "$WGTSERVICENAME" ];then echo "WARN: failed to find name in config.xml, fallback to filename" export WGTSERVICENAME="$WGTNAME" -- 2.16.6 From 4f2971a1e90ce4add03f0ed35f63df57f63e29e8 Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Mon, 31 Aug 2020 13:58:41 +0200 Subject: [PATCH 06/16] SPEC-3484: install and basicly test coverage package Install and test coverage the same way than normal package. Handling coverage generated files will be handled later. Bug-AGL: SPEC-3484 Change-Id: I02d4ea1aa77954a7c85317accb6b565ece8676c0 Signed-off-by: Corentin LABBE --- common/scripts/application-lifecycle.sh | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index b9b3328..f922d02 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -393,7 +393,20 @@ do fi if [ -e $WGTNAME-coverage.wgt ];then inspect_wgt $WGTNAME-coverage.wgt $WGTNAME - echo "DEBUG: coverage not handled yet" + do_release_test $WGTNAME $WGTNAME-coverage.wgt + check_service_running $WGTNAME + if [ $? -eq 1 ];then + afm-util install $TOPDIR/$WGTNAME-test.wgt + do_afm_test $TOPDIR/$WGTNAME-test.wgt + if [ $? -eq 0 ];then + lava-test-case run-test-$WGTNAME --result pass + else + lava-test-case run-test-$WGTNAME --result fail + fi + else + echo "DEBUG: $WGTNAME is not running, skipping test" + lava-test-case run-test-$WGTNAME --result skip + fi fi done -- 2.16.6 From 67d59710fae4eb05fcd4656b6b204caa9506df7d Mon Sep 17 00:00:00 2001 From: Jan-Simon Moeller Date: Mon, 14 Sep 2020 15:53:21 +0200 Subject: [PATCH 07/16] Change regular pyagl invocation to nohw In CI we will execute the 'not hwrequired' flag. Make this the default case in the test-suites. Bug-AGL: SPEC-3572 Signed-off-by: Jan-Simon Moeller Change-Id: I370bb3c12953d7455a1a4c06c573cbc10ee17bda --- common/scripts/pyagl-nohw-lava.sh | 7 +++++++ common/scripts/pyagl-regular-lava.sh | 7 ------- test-suites/short-smoke/pyagl-nohw-oneshot.yaml | 14 ++++++++++++++ test-suites/short-smoke/pyagl-regular-oneshot.yaml | 14 -------------- 4 files changed, 21 insertions(+), 21 deletions(-) create mode 100755 common/scripts/pyagl-nohw-lava.sh delete mode 100755 common/scripts/pyagl-regular-lava.sh create mode 100644 test-suites/short-smoke/pyagl-nohw-oneshot.yaml delete mode 100644 test-suites/short-smoke/pyagl-regular-oneshot.yaml diff --git a/common/scripts/pyagl-nohw-lava.sh b/common/scripts/pyagl-nohw-lava.sh new file mode 100755 index 0000000..1b0c7f3 --- /dev/null +++ b/common/scripts/pyagl-nohw-lava.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# for now play safe and only expect ethernet +export AGL_AVAILABLE_INTERFACES="ethernet" + +pytest --color=no --show-capture=no -k "not hwrequired" /usr/lib/python?.?/site-packages/pyagl/tests/ -L + + diff --git a/common/scripts/pyagl-regular-lava.sh b/common/scripts/pyagl-regular-lava.sh deleted file mode 100755 index a64d9d8..0000000 --- a/common/scripts/pyagl-regular-lava.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash -# for now play safe and only expect ethernet -export AGL_AVAILABLE_INTERFACES="ethernet" - -pytest --color=no --show-capture=no -k "regular and not hwrequired" /usr/lib/python?.?/site-packages/pyagl/tests/ -L - - diff --git a/test-suites/short-smoke/pyagl-nohw-oneshot.yaml b/test-suites/short-smoke/pyagl-nohw-oneshot.yaml new file mode 100644 index 0000000..6dd45f2 --- /dev/null +++ b/test-suites/short-smoke/pyagl-nohw-oneshot.yaml @@ -0,0 +1,14 @@ +# These tests are applicable if the board to be used has at least one CAN interface. + +metadata: + name: pyagl_nohw_oneshot + format: "Lava-Test-Shell Test Definition 1.0" + description: "pyagl_nohw_oneshot" + version: 1.0 + +run: + steps: + - echo "pyagl - no external hardware - oneshot" + - lava-test-set start pyagl-nohw-oneshot + - ./common/scripts/pyagl-nohw-lava.sh + - lava-test-set stop diff --git a/test-suites/short-smoke/pyagl-regular-oneshot.yaml b/test-suites/short-smoke/pyagl-regular-oneshot.yaml deleted file mode 100644 index 0bc53fd..0000000 --- a/test-suites/short-smoke/pyagl-regular-oneshot.yaml +++ /dev/null @@ -1,14 +0,0 @@ -# These tests are applicable if the board to be used has at least one CAN interface. - -metadata: - name: pyagl_regular_oneshot - format: "Lava-Test-Shell Test Definition 1.0" - description: "pyagl_regular_oneshot" - version: 1.0 - -run: - steps: - - echo "pyagl regular oneshot" - - lava-test-set start pyagl-regular-oneshot - - ./common/scripts/pyagl-regular-lava.sh - - lava-test-set stop -- 2.16.6 From 091ec3341da2452fd64ee1a3fc7e71505c5a99a6 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan-Simon=20M=C3=B6ller?= Date: Tue, 15 Sep 2020 23:23:47 +0200 Subject: [PATCH 08/16] Add gitreview file for jellyfish branch MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Update the .gitreview file. Change-Id: Icd21d8eff5838dee07d2b3f32dc2a2b3d0b59e04 Bug-AGL: SPEC-3581 Signed-off-by: Jan-Simon Möller --- .gitreview | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitreview b/.gitreview index 7705f11..c5bb0b4 100644 --- a/.gitreview +++ b/.gitreview @@ -2,4 +2,4 @@ host=gerrit.automotivelinux.org port=29418 project=src/qa-testdefinitions -defaultbranch=master +defaultbranch=jellyfish -- 2.16.6 From 28de853aa86eea3a96b9c1b73848cb8b0de8241c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan-Simon=20M=C3=B6ller?= Date: Tue, 13 Oct 2020 22:49:53 +0200 Subject: [PATCH 09/16] Add AGL_AVAILABLE_INTERFACES to application test MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The standalone run did have it defined, but the application test did mit the setting of AGL_AVAILABLE_INTERFACES=ethernet. If necessary it has to be redefined in the test for bluetooth and wifi per board. Bug-AGL: SPEC-3597 Signed-off-by: Jan-Simon Möller Change-Id: I0772f9a6cc449406785fb167f575d6ca65e6267c (cherry picked from commit ddc64f85cd18ea942d602e761305c0f7f7e1c4c1) --- common/scripts/application-lifecycle.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index f922d02..73bd9eb 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -7,6 +7,9 @@ export COLUMNS=1000 AGLDRIVER=agl-driver +# for pyagl - unless redefined in a test +AGL_AVAILABLE_INTERFACES="ethernet" + while [ $# -ge 1 ] do case $1 in -- 2.16.6 From e821362ff4ea932d55468f6a4dbe7c28366f05a7 Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Wed, 14 Oct 2020 09:18:58 +0200 Subject: [PATCH 10/16] SPEC-3631: Add veth test Add veth test which adds an extra virtual network card for testing. Change-Id: I4e6fef99009830cd016b2124b45b6815192b5ced Bug-AGL: SPEC-3631 Signed-off-by: Corentin LABBE (cherry picked from commit 372171903a7c594f3623f80063f7c986150e17f3) --- test-suites/short-smoke/network-veth.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 test-suites/short-smoke/network-veth.yaml diff --git a/test-suites/short-smoke/network-veth.yaml b/test-suites/short-smoke/network-veth.yaml new file mode 100644 index 0000000..4416ff7 --- /dev/null +++ b/test-suites/short-smoke/network-veth.yaml @@ -0,0 +1,10 @@ +metadata: + format: Lava-Test Test Definition 1.0 + name: veth + description: "Virtual network card installation" +run: + steps: + - ip link add veth0 type veth peer name veth1 + - sleep 2 + - ip addr add 10.1.0.1/24 dev veth0 + - ip addr add 10.1.0.2/24 dev veth1 -- 2.16.6 From a635cd2fe47ddda295fdbeb7f2fed51b3f3470b5 Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Wed, 21 Oct 2020 11:37:32 +0200 Subject: [PATCH 11/16] SPEC-3597: prevent conman to break routes conman break routes after adding veth, prevent this. Change-Id: Ic674a8ad609783950ac2ca95a9176d427c59b6ad Bug-AGL: SPEC-3597 Signed-off-by: Corentin LABBE --- test-suites/short-smoke/network-veth.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test-suites/short-smoke/network-veth.yaml b/test-suites/short-smoke/network-veth.yaml index 4416ff7..25f313e 100644 --- a/test-suites/short-smoke/network-veth.yaml +++ b/test-suites/short-smoke/network-veth.yaml @@ -8,3 +8,5 @@ run: - sleep 2 - ip addr add 10.1.0.1/24 dev veth0 - ip addr add 10.1.0.2/24 dev veth1 + - echo 'DefaultAutoConnectTechnologies=""' >> /etc/connman/main.conf + - systemctl restart connman.service -- 2.16.6 From 16a714e85ce8875f8e53f965050d62c30ad3f6ab Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan-Simon=20M=C3=B6ller?= Date: Thu, 22 Oct 2020 11:20:42 +0200 Subject: [PATCH 12/16] Flip order in veth setup MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jan-Simon Möller Change-Id: I2da141b438122eee2768582c5a31054cb8a68964 --- test-suites/short-smoke/network-veth.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test-suites/short-smoke/network-veth.yaml b/test-suites/short-smoke/network-veth.yaml index 25f313e..c07e2eb 100644 --- a/test-suites/short-smoke/network-veth.yaml +++ b/test-suites/short-smoke/network-veth.yaml @@ -4,9 +4,10 @@ metadata: description: "Virtual network card installation" run: steps: + - echo 'DefaultAutoConnectTechnologies=""' >> /etc/connman/main.conf + - systemctl restart connman.service + - sleep 2 - ip link add veth0 type veth peer name veth1 - sleep 2 - ip addr add 10.1.0.1/24 dev veth0 - ip addr add 10.1.0.2/24 dev veth1 - - echo 'DefaultAutoConnectTechnologies=""' >> /etc/connman/main.conf - - systemctl restart connman.service -- 2.16.6 From 0c5c0f416282e63fa41743cd5c8582ca2f5bcffb Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan-Simon=20M=C3=B6ller?= Date: Wed, 25 Nov 2020 12:25:28 +0100 Subject: [PATCH 13/16] Do not require tests that enforce internet to be available in CI MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Do not enforce tests that require the internet connection to be up. This is the case for geoclue and weather. We might be able to revert this in the future after fixes to the systemd dependencies and lab setup. Signed-off-by: Jan-Simon Möller Change-Id: I1f53e6bfda5be7c9f9613b485efb4f2e25839a63 --- common/scripts/application-lifecycle.sh | 37 +-------------------------------- common/scripts/pyagl-nohw-lava.sh | 2 +- 2 files changed, 2 insertions(+), 37 deletions(-) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index 73bd9eb..403116e 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -368,25 +368,7 @@ do if [ -e $WGTNAME.wgt ];then inspect_wgt $WGTNAME.wgt $WGTNAME do_release_test $WGTNAME $WGTNAME.wgt - else - echo "WARN: cannot find $WGTNAME.wgt" - fi - if [ -e $WGTNAME-test.wgt ];then - # wgt-test do not have the same permissions in the config.xml as the parent wgt - # so keep the value from last run - #inspect_wgt $WGTNAME-test.wgt - check_service_running $WGTNAME - if [ $? -eq 1 ];then - do_afm_test $TOPDIR/$WGTNAME-test.wgt - if [ $? -eq 0 ];then - lava-test-case run-test-$WGTNAME --result pass - else - lava-test-case run-test-$WGTNAME --result fail - fi - else - echo "DEBUG: $WGTNAME is not running, skipping test" - lava-test-case run-test-$WGTNAME --result skip - fi + pytest --show-capture=no --color=no -k "not hwrequired and not internet" /usr/lib/python?.?/site-packages/pyagl/tests/ -L else echo "WARN: cannot find $WGTNAME.wgt" fi @@ -394,22 +376,5 @@ do inspect_wgt $WGTNAME-debug.wgt $WGTNAME do_release_test $WGTNAME $WGTNAME-debug.wgt fi - if [ -e $WGTNAME-coverage.wgt ];then - inspect_wgt $WGTNAME-coverage.wgt $WGTNAME - do_release_test $WGTNAME $WGTNAME-coverage.wgt - check_service_running $WGTNAME - if [ $? -eq 1 ];then - afm-util install $TOPDIR/$WGTNAME-test.wgt - do_afm_test $TOPDIR/$WGTNAME-test.wgt - if [ $? -eq 0 ];then - lava-test-case run-test-$WGTNAME --result pass - else - lava-test-case run-test-$WGTNAME --result fail - fi - else - echo "DEBUG: $WGTNAME is not running, skipping test" - lava-test-case run-test-$WGTNAME --result skip - fi - fi done diff --git a/common/scripts/pyagl-nohw-lava.sh b/common/scripts/pyagl-nohw-lava.sh index 1b0c7f3..06dddb9 100755 --- a/common/scripts/pyagl-nohw-lava.sh +++ b/common/scripts/pyagl-nohw-lava.sh @@ -2,6 +2,6 @@ # for now play safe and only expect ethernet export AGL_AVAILABLE_INTERFACES="ethernet" -pytest --color=no --show-capture=no -k "not hwrequired" /usr/lib/python?.?/site-packages/pyagl/tests/ -L +pytest --color=no --show-capture=no -k "not hwrequired and not internet" /usr/lib/python?.?/site-packages/pyagl/tests/ -L -- 2.16.6 From 132a833658be8bc3ebff1919178bac06f0a27e58 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan-Simon=20M=C3=B6ller?= Date: Fri, 27 Nov 2020 15:09:28 +0100 Subject: [PATCH 14/16] Disable colors in journal dump MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Avoid escaping characters. Signed-off-by: Jan-Simon Möller Change-Id: I50b1895cc148b43a73e8730f76a39c29382973cb (cherry picked from commit 4e8207f132f93636b19ff868186063ad026bca8a) --- common/scripts/dumpjournal.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/scripts/dumpjournal.sh b/common/scripts/dumpjournal.sh index fdbe036..696b994 100755 --- a/common/scripts/dumpjournal.sh +++ b/common/scripts/dumpjournal.sh @@ -19,6 +19,6 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # -journalctl -a --no-pager +SYSTEMD_COLORS=false journalctl -a --no-pager echo "dumpjournal: pass" exit 0 -- 2.16.6 From 7007258d954d544a9f859ba51633ae6b5a0a3925 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan-Simon=20M=C3=B6ller?= Date: Wed, 13 Jan 2021 17:34:39 +0100 Subject: [PATCH 15/16] Update pyagl testdefinition to set AGL_CAN_INTERFACE MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit We need to use vcan0 for the canreplay. Bug-AGL: SPEC-3756 Signed-off-by: Jan-Simon Möller Change-Id: I8e3e8c7d6eadf081014e129cfd59ad217004f46d --- common/scripts/pyagl-nohw-lava.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/common/scripts/pyagl-nohw-lava.sh b/common/scripts/pyagl-nohw-lava.sh index 06dddb9..0975d7d 100755 --- a/common/scripts/pyagl-nohw-lava.sh +++ b/common/scripts/pyagl-nohw-lava.sh @@ -1,6 +1,7 @@ #!/bin/bash # for now play safe and only expect ethernet export AGL_AVAILABLE_INTERFACES="ethernet" +export AGL_CAN_INTERFACE="vcan0" pytest --color=no --show-capture=no -k "not hwrequired and not internet" /usr/lib/python?.?/site-packages/pyagl/tests/ -L -- 2.16.6 From 1cba00345f7c2cf81a36297ecae83ffb133bff22 Mon Sep 17 00:00:00 2001 From: Jan-Simon Moeller Date: Fri, 15 Jan 2021 23:51:34 +0100 Subject: [PATCH 16/16] Add AGL_CAN_INTERFACE=vcan0 to application-lifecycle Signed-off-by: Jan-Simon Moeller Change-Id: Ic0b2e75122835786899aae2979feb8d29edefd5c --- common/scripts/application-lifecycle.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/scripts/application-lifecycle.sh b/common/scripts/application-lifecycle.sh index 403116e..6e7394f 100755 --- a/common/scripts/application-lifecycle.sh +++ b/common/scripts/application-lifecycle.sh @@ -8,7 +8,8 @@ export COLUMNS=1000 AGLDRIVER=agl-driver # for pyagl - unless redefined in a test -AGL_AVAILABLE_INTERFACES="ethernet" +export AGL_AVAILABLE_INTERFACES="ethernet" +export AGL_CAN_INTERFACE="vcan0" while [ $# -ge 1 ] do -- 2.16.6