From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id B0BF91B6A8 for ; Wed, 9 May 2018 16:42:36 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 May 2018 07:42:35 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,381,1520924400"; d="scan'208";a="53732398" Received: from kchalupx-mobl.ger.corp.intel.com ([10.103.104.151]) by fmsmga001.fm.intel.com with ESMTP; 09 May 2018 07:42:34 -0700 From: Kamil Chalupnik To: dev@dpdk.org Cc: amr.mokhtar@intel.com, pablo.de.lara.guarch@intel.com, KamilX Chalupnik Date: Wed, 9 May 2018 16:42:10 +0200 Message-Id: <20180509144210.21104-1-kamilx.chalupnik@intel.com> X-Mailer: git-send-email 2.9.0.windows.1 In-Reply-To: <20180426133008.12388-13-kamilx.chalupnik@intel.com> References: <20180426133008.12388-13-kamilx.chalupnik@intel.com> Subject: [dpdk-dev] [PATCH v2 11/14] app/bbdev: improve readability of test application X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 09 May 2018 14:42:37 -0000 From: KamilX Chalupnik Improve readability of test application by replacing int values with rte_bbdev_event_type enum Signed-off-by: Kamil Chalupnik --- app/test-bbdev/test_bbdev.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/app/test-bbdev/test_bbdev.c b/app/test-bbdev/test_bbdev.c index 5d325b6..a914817 100644 --- a/app/test-bbdev/test_bbdev.c +++ b/app/test-bbdev/test_bbdev.c @@ -895,12 +895,12 @@ test_bbdev_callback(void) "Failed to callback rgstr for RTE_BBDEV_EVENT_UNKNOWN"); rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_UNKNOWN, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process " "for RTE_BBDEV_EVENT_UNKNOWN "); rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_ERROR, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process: " "event RTE_BBDEV_EVENT_ERROR was not registered "); @@ -919,12 +919,12 @@ test_bbdev_callback(void) event_status = -1; rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_UNKNOWN, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process " "for RTE_BBDEV_EVENT_UNKNOWN "); rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_ERROR, NULL); - TEST_ASSERT(event_status == 1, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_ERROR, "Failed test for rte_bbdev_pmd_callback_process " "for RTE_BBDEV_EVENT_ERROR "); @@ -938,12 +938,12 @@ test_bbdev_callback(void) event_status = -1; rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_UNKNOWN, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process " "for RTE_BBDEV_EVENT_UNKNOWN "); rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_ERROR, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process: " "event RTE_BBDEV_EVENT_ERROR was unregistered "); @@ -992,7 +992,7 @@ test_bbdev_callback(void) "for RTE_BBDEV_EVENT_ERROR "); rte_bbdev_pmd_callback_process(dev2, RTE_BBDEV_EVENT_ERROR, NULL); - TEST_ASSERT(event_status == 1, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_ERROR, "Failed test for rte_bbdev_pmd_callback_process in dev2 " "for RTE_BBDEV_EVENT_ERROR "); @@ -1006,7 +1006,7 @@ test_bbdev_callback(void) "in dev 2 "); rte_bbdev_pmd_callback_process(dev2, RTE_BBDEV_EVENT_UNKNOWN, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process in dev2" " for RTE_BBDEV_EVENT_UNKNOWN "); @@ -1026,7 +1026,7 @@ test_bbdev_callback(void) " for RTE_BBDEV_EVENT_UNKNOWN "); rte_bbdev_pmd_callback_process(dev1, RTE_BBDEV_EVENT_UNKNOWN, NULL); - TEST_ASSERT(event_status == 0, + TEST_ASSERT(event_status == (int) RTE_BBDEV_EVENT_UNKNOWN, "Failed test for rte_bbdev_pmd_callback_process in dev2 " "for RTE_BBDEV_EVENT_UNKNOWN "); -- 2.5.5