From patchwork Fri Aug 15 20:37:42 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Mason, Michael W" X-Patchwork-Id: 4729381 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.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 17CCC9F377 for ; Fri, 15 Aug 2014 20:38:30 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2736C201EF for ; Fri, 15 Aug 2014 20:38:29 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 512E2201ED for ; Fri, 15 Aug 2014 20:38:28 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B91B16E820; Fri, 15 Aug 2014 13:38:27 -0700 (PDT) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTP id 4CEB86E820 for ; Fri, 15 Aug 2014 13:38:27 -0700 (PDT) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP; 15 Aug 2014 13:38:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.01,873,1400050800"; d="scan'208";a="588758136" Received: from orsmsx105.amr.corp.intel.com ([10.22.225.132]) by orsmga002.jf.intel.com with ESMTP; 15 Aug 2014 13:37:43 -0700 Received: from orsmsx115.amr.corp.intel.com ([169.254.10.235]) by ORSMSX105.amr.corp.intel.com ([169.254.4.51]) with mapi id 14.03.0195.001; Fri, 15 Aug 2014 13:37:42 -0700 From: "Mason, Michael W" To: "intel-gfx@lists.freedesktop.org" Thread-Topic: [Intel-gfx][PATCH i-g-t 1/1] scripts: Allow multiple -t and -x regular expressions for run-tests.sh Thread-Index: Ac+4yK76fycLszh3SmOG8qUckNwoAA== Date: Fri, 15 Aug 2014 20:37:42 +0000 Message-ID: <01CCE187461CCB4CA621763B9BFAEC4050EC28@ORSMSX115.amr.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.22.254.140] MIME-Version: 1.0 Subject: [Intel-gfx] [PATCH i-g-t 1/1] scripts: Allow multiple -t and -x regular expressions for run-tests.sh X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, 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 Piglit allows multiple -t and -x regular expressions to be given on the command line. This patch enables run-tests.sh to support that as well. Signed-off-by: Mike Mason --- scripts/run-tests.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/run-tests.sh b/scripts/run-tests.sh index cf77473..d0e0c67 100755 --- a/scripts/run-tests.sh +++ b/scripts/run-tests.sh @@ -55,8 +55,10 @@ function print_help { echo " (default: $RESULTS)" echo " -s create html summary" echo " -t only include tests that match the regular expression" + echo " (can be used more than once)" echo " -v enable verbose mode" echo " -x exclude tests that match the regular expression" + echo " (can be used more than once)" echo "" echo "Useful patterns for test filtering are described in tests/NAMING-CONVENTION" } @@ -78,9 +80,9 @@ while getopts ":dhlr:st:vx:" opt; do l) list_tests; exit ;; r) RESULTS="$OPTARG" ;; s) SUMMARY="html" ;; - t) FILTER="-t $OPTARG" ;; + t) FILTER="$FILTER -t $OPTARG" ;; v) VERBOSE="-v" ;; - x) EXCLUDE="-x $OPTARG" ;; + x) EXCLUDE="$EXCLUDE -x $OPTARG" ;; :) echo "Option -$OPTARG requires an argument." exit 1