From patchwork Tue Jun 14 18:48:24 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paul Larson X-Patchwork-Id: 1822 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 2687123E50 for ; Tue, 14 Jun 2011 18:48:27 +0000 (UTC) Received: from mail-vx0-f180.google.com (mail-vx0-f180.google.com [209.85.220.180]) by fiordland.canonical.com (Postfix) with ESMTP id D9D9DA1817D for ; Tue, 14 Jun 2011 18:48:26 +0000 (UTC) Received: by vxk12 with SMTP id 12so6886517vxk.11 for ; Tue, 14 Jun 2011 11:48:26 -0700 (PDT) Received: by 10.52.112.106 with SMTP id ip10mr7835038vdb.127.1308077306286; Tue, 14 Jun 2011 11:48:26 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.52.183.130 with SMTP id em2cs81134vdc; Tue, 14 Jun 2011 11:48:26 -0700 (PDT) Received: by 10.216.235.95 with SMTP id t73mr1462080weq.10.1308077305111; Tue, 14 Jun 2011 11:48:25 -0700 (PDT) Received: from adelie.canonical.com (adelie.canonical.com [91.189.90.139]) by mx.google.com with ESMTP id b67si16421931wek.96.2011.06.14.11.48.24; Tue, 14 Jun 2011 11:48:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.139 as permitted sender) client-ip=91.189.90.139; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.139 as permitted sender) smtp.mail=bounces@canonical.com Received: from loganberry.canonical.com ([91.189.90.37]) by adelie.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1QWYf2-0007K7-AY for ; Tue, 14 Jun 2011 18:48:24 +0000 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id 4C6A62E899B for ; Tue, 14 Jun 2011 18:48:24 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: lava-test X-Launchpad-Branch: ~linaro-validation/lava-test/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 71 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-validation/lava-test/trunk] Rev 71: Add analyzer_assigned_uuid back (previously removed due to bad commit) Message-Id: <20110614184824.2910.83464.launchpad@loganberry.canonical.com> Date: Tue, 14 Jun 2011 18:48:24 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="13216"; Instance="initZopeless config overlay" X-Launchpad-Hash: 699430269f98698a5b7f077b55f3243df683934c ------------------------------------------------------------ revno: 71 committer: Paul Larson branch nick: lava-test timestamp: Tue 2011-06-14 13:43:45 -0500 message: Add analyzer_assigned_uuid back (previously removed due to bad commit) modified: abrek/testdef.py --- lp:lava-test https://code.launchpad.net/~linaro-validation/lava-test/trunk You are subscribed to branch lp:lava-test. To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-test/trunk/+edit-subscription === modified file 'abrek/testdef.py' --- abrek/testdef.py 2011-06-07 21:18:06 +0000 +++ abrek/testdef.py 2011-06-14 18:43:45 +0000 @@ -21,6 +21,7 @@ import time from commands import getstatusoutput from datetime import datetime +from uuid import uuid1 from abrek import swprofile, hwprofile from abrek.api import ITest @@ -91,7 +92,7 @@ if os.path.exists(path): shutil.rmtree(path) - def _savetestdata(self): + def _savetestdata(self, analyzer_assigned_uuid): TIMEFORMAT = '%Y-%m-%dT%H:%M:%SZ' bundle = { 'format': 'Dashboard Bundle Format 1.2', @@ -99,6 +100,7 @@ { 'test_id': self.testname, 'analyzer_assigned_date': self.runner.starttime.strftime(TIMEFORMAT), + 'analyzer_assigned_uuid': analyzer_assigned_uuid, 'time_check_performed': False, 'hardware_context': hwprofile.get_hardware_context(), 'software_context': swprofile.get_software_context(), @@ -114,6 +116,7 @@ raise RuntimeError("no test runner defined for '%s'" % self.testname) config = get_config() + uuid = str(uuid1()) installdir = os.path.join(config.installdir, self.testname) resultname = (self.testname + str(time.mktime(datetime.utcnow().timetuple()))) @@ -122,7 +125,7 @@ try: os.chdir(installdir) self.runner.run(self.resultsdir, quiet=quiet) - self._savetestdata() + self._savetestdata(uuid) finally: os.chdir(self.origdir) result_id = os.path.basename(self.resultsdir)