From patchwork Fri Jul 3 15:45:37 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Milard X-Patchwork-Id: 50642 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f69.google.com (mail-wg0-f69.google.com [74.125.82.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 6D4DB22916 for ; Fri, 3 Jul 2015 15:47:10 +0000 (UTC) Received: by wgjx7 with SMTP id x7sf31223256wgj.3 for ; Fri, 03 Jul 2015 08:47:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:delivered-to:from:to:date :message-id:in-reply-to:references:cc:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :mime-version:content-type:content-transfer-encoding:errors-to :sender:x-original-sender:x-original-authentication-results :mailing-list; bh=W2BupOo2/5OX4tAxVi+fRPpAcY5DLcIE78S0i9GVkx4=; b=cQtn0R7+SKz+jfju5loYHX1l19gAfk+wj4A/fGWKgOg+nNlHk70eWYkJAUtqXcMAWT x5O5aTrPbr072ONWYMQiRa1R8WhrtMJytE+jz+oTWeM9kJnrL6AlPnqQwXzHAB8QtV5/ veKgvz82fy6kw9jKrd0aiHSKtuuC3za4FZI+onF8Ft/pfSicq+C1vAiQe9c4Sm1PQ/s5 /vsinRQefFHVoizOuAA9SW6dKh/nygsM3A/59/uPFKOoY0cQSL/QmlOQjpWmiijj4CrB 3EFeileYn7rCPBUZ1az7tD/nmw7rBYTko4PQvch2guwEvcAZoWCzSuSaKYj2pB7jxa9w vYCw== X-Gm-Message-State: ALoCoQmV/x+bO4B5qJKOxthsSm6OAy2KVe3Q4ApGxC/3JjOUVZeSnHXy1rLyoRxA+uPRAPAFF22f X-Received: by 10.112.253.135 with SMTP id aa7mr12175784lbd.11.1435938429682; Fri, 03 Jul 2015 08:47:09 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.184.168 with SMTP id ev8ls476532lac.44.gmail; Fri, 03 Jul 2015 08:47:09 -0700 (PDT) X-Received: by 10.152.43.110 with SMTP id v14mr36481211lal.4.1435938429529; Fri, 03 Jul 2015 08:47:09 -0700 (PDT) Received: from mail-la0-f47.google.com (mail-la0-f47.google.com. [209.85.215.47]) by mx.google.com with ESMTPS id uh5si7499619lac.168.2015.07.03.08.47.08 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 03 Jul 2015 08:47:08 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.47 as permitted sender) client-ip=209.85.215.47; Received: by lagx9 with SMTP id x9so89725301lag.1 for ; Fri, 03 Jul 2015 08:47:08 -0700 (PDT) X-Received: by 10.152.42.177 with SMTP id p17mr36315682lal.29.1435938428023; Fri, 03 Jul 2015 08:47:08 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp113302lbb; Fri, 3 Jul 2015 08:47:07 -0700 (PDT) X-Received: by 10.55.21.41 with SMTP id f41mr74837993qkh.48.1435938426707; Fri, 03 Jul 2015 08:47:06 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id j201si10717640qhc.130.2015.07.03.08.47.01; Fri, 03 Jul 2015 08:47:06 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Received: by lists.linaro.org (Postfix, from userid 109) id 7F47462066; Fri, 3 Jul 2015 15:47:01 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from ip-10-142-244-252.ec2.internal (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 3D32B61D4E; Fri, 3 Jul 2015 15:46:10 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 0BC5862056; Fri, 3 Jul 2015 15:46:04 +0000 (UTC) Received: from mail-la0-f46.google.com (mail-la0-f46.google.com [209.85.215.46]) by lists.linaro.org (Postfix) with ESMTPS id 5B20461CAF for ; Fri, 3 Jul 2015 15:45:57 +0000 (UTC) Received: by lagc2 with SMTP id c2so89742464lag.3 for ; Fri, 03 Jul 2015 08:45:56 -0700 (PDT) X-Received: by 10.112.126.136 with SMTP id my8mr36145973lbb.18.1435938356185; Fri, 03 Jul 2015 08:45:56 -0700 (PDT) Received: from erachmi-VirtualBox.ki.sw.ericsson.se (c-83-233-90-46.cust.bredband2.com. [83.233.90.46]) by mx.google.com with ESMTPSA id fb5sm2416637lbc.35.2015.07.03.08.45.54 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 03 Jul 2015 08:45:55 -0700 (PDT) From: Christophe Milard To: anders.roxell@linaro.org, mike.holmes@linaro.org, stuart.haslam@linaro.org, maxim.uvarov@linaro.org Date: Fri, 3 Jul 2015 17:45:37 +0200 Message-Id: <1435938340-7512-3-git-send-email-christophe.milard@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1435938340-7512-1-git-send-email-christophe.milard@linaro.org> References: <1435938340-7512-1-git-send-email-christophe.milard@linaro.org> X-Topics: timers patch Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [PATCH 2/5] validation: renaming in odp_timer.c X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: christophe.milard@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.47 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Renaming of things which may be, one day, exported in a lib. This renaming is important, as it creates consistency between test symbols, which is needed if things get eventually exported in the lib. Also, tests are often created from other tests: Fixing the first exemples will help geting future tests better. Things that are candidate to be exported in the lib in the future have been named as follows: -Tests, i.e. functions which are used in CUNIT testsuites are named: _test_* -Test arrays, i.e. arrays of CU_TestInfo, listing the test functions belonging to a suite, are called: _suite[_*] where the possible suffix can be used if many suites are declared. -CUNIT suite init and termination functions are called: _suite[_*]_init() and _suite[_*]_term() respectively. -Suite arrays, i.e. arrays of CU_SuiteInfo used in executables are called: _suites[_*] where the possible suffix identifies the executable using it, if many. -Main function(s), are called: _main[_*] where the possible suffix identifies the executable using it Signed-off-by: Christophe Milard --- test/validation/odp_timer.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/test/validation/odp_timer.c b/test/validation/odp_timer.c index bff585e..3ab395d 100644 --- a/test/validation/odp_timer.c +++ b/test/validation/odp_timer.c @@ -49,7 +49,7 @@ struct test_timer { #define TICK_INVALID (~(uint64_t)0) -static void test_timeout_pool_alloc(void) +static void timer_test_timeout_pool_alloc(void) { odp_pool_t pool; const int num = 3; @@ -93,7 +93,7 @@ static void test_timeout_pool_alloc(void) CU_ASSERT(odp_pool_destroy(pool) == 0); } -static void test_timeout_pool_free(void) +static void timer_test_timeout_pool_free(void) { odp_pool_t pool; odp_timeout_t tmo; @@ -124,7 +124,7 @@ static void test_timeout_pool_free(void) CU_ASSERT(odp_pool_destroy(pool) == 0); } -static void test_odp_timer_cancel(void) +static void timer_test_odp_timer_cancel(void) { odp_pool_t pool; odp_pool_param_t params; @@ -434,7 +434,7 @@ static void *worker_entrypoint(void *arg TEST_UNUSED) } /* @private Timer test case entrypoint */ -static void test_odp_timer_all(void) +static void timer_test_odp_timer_all(void) { int rc; odp_pool_param_t params; @@ -527,16 +527,16 @@ static void test_odp_timer_all(void) CU_PASS("ODP timer test"); } -static CU_TestInfo test_odp_timer[] = { - {"test_timeout_pool_alloc", test_timeout_pool_alloc}, - {"test_timeout_pool_free", test_timeout_pool_free}, - {"test_odp_timer_cancel", test_odp_timer_cancel}, - {"test_odp_timer_all", test_odp_timer_all}, +static CU_TestInfo timer_suite[] = { + {"test_timeout_pool_alloc", timer_test_timeout_pool_alloc}, + {"test_timeout_pool_free", timer_test_timeout_pool_free}, + {"test_odp_timer_cancel", timer_test_odp_timer_cancel}, + {"test_odp_timer_all", timer_test_odp_timer_all}, CU_TEST_INFO_NULL, }; static CU_SuiteInfo timer_suites[] = { - {"Timer", NULL, NULL, NULL, NULL, test_odp_timer}, + {"Timer", NULL, NULL, NULL, NULL, timer_suite}, CU_SUITE_INFO_NULL, };