Fix misleading output messages 74/286774/4
authorAntoni Adaszkiewicz <a.adaszkiewi@samsung.com>
Thu, 12 Jan 2023 14:31:08 +0000 (15:31 +0100)
committerAntoni Adaszkiewicz <a.adaszkiewi@samsung.com>
Mon, 13 Feb 2023 13:33:11 +0000 (14:33 +0100)
Change-Id: I2ccea575a7608f0238e29f06f409f2f102f27cef

test/peripheral-io-test.c

index c5bee68..420445a 100644 (file)
@@ -76,7 +76,7 @@ static int __get_feature(const char *key, bool *feature)
        int ret = SYSTEM_INFO_ERROR_NONE;
        ret = system_info_get_platform_bool(key, feature);
        if (ret != SYSTEM_INFO_ERROR_NONE) {
-               printf("[Message] Failed to feature (%s).\n\n", key);
+               printf("[Message] Failed to get feature (%s).\n\n", key);
                return PERIPHERAL_ERROR_NOT_SUPPORTED;
        }
        return PERIPHERAL_ERROR_NONE;
@@ -121,10 +121,9 @@ static int __test_peripheral_init(const char *test_name, const char *key_feature
        }
 
        ret = __get_feature(key_feature, &feature);
-       if (ret != PERIPHERAL_ERROR_NONE) {
-               printf("[Message] Feature %s not supported\n", key_feature);
+       if (ret != PERIPHERAL_ERROR_NONE)
                return ret;
-       }
+       printf("[Message] Feature %s is %s on the device (tests also verify support).\n", key_feature, feature == true ? "supported" : "not supported");
 
        ret = init_fn(model_name, feature);
        if (ret != PERIPHERAL_ERROR_NONE) {