From patchwork Wed May 6 00:14:55 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mason, Michael W" X-Patchwork-Id: 6344751 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 5C1669F373 for ; Wed, 6 May 2015 00:11:05 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7B59520222 for ; Wed, 6 May 2015 00:11:04 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 6FFDF20220 for ; Wed, 6 May 2015 00:11:03 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 64F0F6E2DB; Tue, 5 May 2015 17:11:02 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by gabe.freedesktop.org (Postfix) with ESMTP id 9AC916E13A for ; Tue, 5 May 2015 17:11:01 -0700 (PDT) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP; 05 May 2015 17:11:02 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,376,1427785200"; d="scan'208";a="724315521" Received: from otc-chrmqaubu-05.jf.intel.com ([10.7.202.166]) by orsmga002.jf.intel.com with ESMTP; 05 May 2015 17:11:01 -0700 From: Mike Mason To: intel-gfx@lists.freedesktop.org Date: Tue, 5 May 2015 17:14:55 -0700 Message-Id: <1430871295-25300-1-git-send-email-michael.w.mason@intel.com> X-Mailer: git-send-email 1.9.1 Subject: [Intel-gfx] [PATCH i-g-t] scripts/run-tests.sh: use single combined test list X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP i-g-t now creates a single combined test list for tests with and without subtests. This patch adapts run-tests.sh to that change. Signed-off-by: Mike Mason --- scripts/run-tests.sh | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/scripts/run-tests.sh b/scripts/run-tests.sh index 5f83dcf..d65e813 100755 --- a/scripts/run-tests.sh +++ b/scripts/run-tests.sh @@ -33,13 +33,13 @@ if [ ! -d "$IGT_TEST_ROOT" ]; then exit 1 fi -if [ ! -f "$IGT_TEST_ROOT/single-tests.txt" ]; then +if [ ! -f "$IGT_TEST_ROOT/test-list.txt" ]; then echo "Error: test list not found." echo "Please run make in the tests directory to generate the test list." + exit 1 fi -SINGLE_TEST_LIST=`cat "$IGT_TEST_ROOT/single-tests.txt" | sed -e '/TESTLIST/d' -e 's/ /\n/g'` -MULTI_TEST_LIST=`cat "$IGT_TEST_ROOT/multi-tests.txt" | sed -e '/TESTLIST/d' -e 's/ /\n/g'` +TEST_LIST=`cat "$IGT_TEST_ROOT/test-list.txt" | sed -e '/TESTLIST/d' -e 's/ /\n/g'` function download_piglit { git clone git://anongit.freedesktop.org/piglit "$ROOT/piglit" @@ -66,12 +66,15 @@ function print_help { } function list_tests { - echo "$SINGLE_TEST_LIST" - for test in $MULTI_TEST_LIST; do + for test in $TEST_LIST; do SUBTESTS=`"$IGT_TEST_ROOT/$test" --list-subtests` - for subtest in $SUBTESTS; do - echo "$test/$subtest" - done + if [ -z "$SUBTESTS" ]; then + echo "$test" + else + for subtest in $SUBTESTS; do + echo "$test/$subtest" + done + fi done }