From patchwork Wed Apr 20 13:41:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Feceoru, Gabriel" X-Patchwork-Id: 8890031 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 29A539F441 for ; Wed, 20 Apr 2016 13:41:27 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5AEE2201FA for ; Wed, 20 Apr 2016 13:41:26 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 845392015E for ; Wed, 20 Apr 2016 13:41:25 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B42576E9D7; Wed, 20 Apr 2016 13:41:24 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by gabe.freedesktop.org (Postfix) with ESMTP id C0C016E9D7 for ; Wed, 20 Apr 2016 13:41:22 +0000 (UTC) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP; 20 Apr 2016 06:41:22 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,509,1455004800"; d="scan'208";a="936431327" Received: from gfeceoru-ms-7924.rb.intel.com ([10.237.104.199]) by orsmga001.jf.intel.com with ESMTP; 20 Apr 2016 06:41:21 -0700 From: Gabriel Feceoru To: intel-gfx@lists.freedesktop.org Date: Wed, 20 Apr 2016 16:41:42 +0300 Message-Id: <1461159702-11791-1-git-send-email-gabriel.feceoru@intel.com> X-Mailer: git-send-email 1.9.1 Subject: [Intel-gfx] [PATCH i-g-t] scripts: Fix outdated quick-testlist.py 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=-5.2 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 changed the format of the result json file, replacing time attribute float with a TimeAttribute object, which stores a start time and an end time. Fixed this script by calculating the duration when reading the json results. Signed-off-by: Gabriel Feceoru --- scripts/quick-testlist.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/quick-testlist.py b/scripts/quick-testlist.py index 0dd4c69..ffd6bb9 100755 --- a/scripts/quick-testlist.py +++ b/scripts/quick-testlist.py @@ -32,7 +32,11 @@ def filter_results(filename): for test_name in json_data["tests"]: if json_data["tests"][test_name]["result"] == "incomplete": continue - if json_data["tests"][test_name]["time"] < 60: + + duration = json_data["tests"][test_name]["time"]['end'] - \ + json_data["tests"][test_name]["time"]['start'] + + if duration < 60: print(test_name)