From 21ff1fdd2d91b89550b54f0fed91b58488fa9228 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Po=C5=82awski?= Date: Mon, 20 Apr 2026 20:39:04 +0200 Subject: [PATCH] chore: Update mender-artifact arguments to match latest version MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In the latest version of mender-artifact parameter `--device-type` has been replaced with `--compatible-types`. This requires update all mender-artifact calls which still use old version of argument name. Ticket: MEN-9344 Signed-off-by: Paweł Poławski --- tests/MenderAPI/artifacts.py | 4 ++-- tests/tests/common_artifact.py | 2 +- testutils/common.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/MenderAPI/artifacts.py b/tests/MenderAPI/artifacts.py index b12bef3e5..5ca7853d1 100644 --- a/tests/MenderAPI/artifacts.py +++ b/tests/MenderAPI/artifacts.py @@ -49,7 +49,7 @@ def make_rootfs_artifact( assert os.path.exists(private_key), "private key for testing doesn't exist" signed_arg = "-k %s" % (private_key) - cmd = "%s %s write rootfs-image -f %s -t %s -n %s -o %s %s %s" % ( + cmd = "%s %s write rootfs-image -f %s -c %s -n %s -o %s %s %s" % ( self.artifacts_tool_path, global_flags, image, @@ -98,7 +98,7 @@ def make_module_artifact( assert os.path.exists(private_key), "private key for testing doesn't exist" signed_arg = "-k %s" % (private_key) - cmd = "%s %s write module-image -T %s -t %s -n %s -o %s %s %s %s" % ( + cmd = "%s %s write module-image -T %s -c %s -n %s -o %s %s %s %s" % ( self.artifacts_tool_path, global_flags, module_type, diff --git a/tests/tests/common_artifact.py b/tests/tests/common_artifact.py index cfee0d969..ff0ec11da 100644 --- a/tests/tests/common_artifact.py +++ b/tests/tests/common_artifact.py @@ -28,7 +28,7 @@ def get_script_artifact( logger.info(f"Script: {out}") script_path = tf.name - cmd = f"mender-artifact write module-image -T script -n {artifact_name} -t {device_type} -o {output_path} -f {script_path}" + cmd = f"mender-artifact write module-image -T script -n {artifact_name} -c {device_type} -o {output_path} -f {script_path}" if extra_args is not None: cmd += f" {extra_args}" diff --git a/testutils/common.py b/testutils/common.py index ce207dea2..15da544ff 100644 --- a/testutils/common.py +++ b/testutils/common.py @@ -395,7 +395,7 @@ def get_mender_artifact( filename, ] for device_type in device_types: - args.extend(["-t", device_type]) + args.extend(["-c", device_type]) for depend in depends: args.extend(["--depends", depend]) for provide in provides: