From ac6c0a2997fa8ea34bf06a5e6a00a39a1fe70483 Mon Sep 17 00:00:00 2001 From: Oliver Smith Date: Wed, 7 Nov 2018 07:48:08 +0100 Subject: [PATCH] test_aports.py: disallow noarch device packages Check if all device packages have the same arch in their device APKBUILD as they have in their deviceinfo. And that they have !archcheck set in the options. --- .gitlab-ci/testcases/test_aports.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.gitlab-ci/testcases/test_aports.py b/.gitlab-ci/testcases/test_aports.py index eb60e3acd..a727af77e 100644 --- a/.gitlab-ci/testcases/test_aports.py +++ b/.gitlab-ci/testcases/test_aports.py @@ -83,6 +83,15 @@ def test_aports_device(args): " subpackages now, see" " .") + # Architecture + device = apkbuild["pkgname"][len("device-"):] + deviceinfo = pmb.parse.deviceinfo(args, device) + if "".join(apkbuild["arch"]) != deviceinfo["arch"]: + raise RuntimeError("wrong architecture, please change to arch=\"" + + deviceinfo["arch"] + "\": " + path) + if "!archcheck" not in apkbuild["options"]: + raise RuntimeError("!archcheck missing in options= line: " + path) + def test_aports_device_kernel(args): """