From patchwork Sun May 24 15:46:47 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Goldish X-Patchwork-Id: 25602 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n4OFim5x012470 for ; Sun, 24 May 2009 15:44:48 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755121AbZEXPoi (ORCPT ); Sun, 24 May 2009 11:44:38 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755045AbZEXPoi (ORCPT ); Sun, 24 May 2009 11:44:38 -0400 Received: from mx2.redhat.com ([66.187.237.31]:49724 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755102AbZEXPog (ORCPT ); Sun, 24 May 2009 11:44:36 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n4OFicRN029881 for ; Sun, 24 May 2009 11:44:38 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx2.corp.redhat.com (8.13.1/8.13.1) with ESMTP id n4OFibvd019952; Sun, 24 May 2009 11:44:37 -0400 Received: from localhost.localdomain (dhcp-1-188.tlv.redhat.com [10.35.1.188]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id n4OFiMU5009023; Sun, 24 May 2009 11:44:36 -0400 From: Michael Goldish To: kvm@vger.kernel.org Cc: Michael Goldish Subject: [KVM-AUTOTEST PATCH] kvm_runtest_2.py: use environment filename specified by the 'env' parameter Date: Sun, 24 May 2009 18:46:47 +0300 Message-Id: <626078156e56b4fd573de078b2f1424e47e8f637.1243179847.git.mgoldish@redhat.com> In-Reply-To: References: <8e37a36c044c20259dcd8a34d72a651e85b37d5f.1243179847.git.mgoldish@redhat.com> <838bcae1b49be011e2cde1294a391a296059464a.1243179847.git.mgoldish@redhat.com> <6a70cb56a775fdb688da0231073abb0ce4baa7b1.1243179847.git.mgoldish@redhat.com> <63bacaa214ccd95c18fb644056855acd72757ac4.1243179847.git.mgoldish@redhat.com> <43f85767b32b927ca5e32abc5ded281915343656.1243179847.git.mgoldish@redhat.com> In-Reply-To: <8e37a36c044c20259dcd8a34d72a651e85b37d5f.1243179847.git.mgoldish@redhat.com> References: <8e37a36c044c20259dcd8a34d72a651e85b37d5f.1243179847.git.mgoldish@redhat.com> X-Scanned-By: MIMEDefang 2.58 on 172.16.27.26 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org Do not use hardcoded environment filename 'env'. Instead use the value specified by the 'env' parameter. If unspecified, use 'env' as the filename. This is important for parallel execution; it may be necessary to use a separate environment file for each process. Signed-off-by: Michael Goldish --- client/tests/kvm_runtest_2/kvm_runtest_2.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/client/tests/kvm_runtest_2/kvm_runtest_2.py b/client/tests/kvm_runtest_2/kvm_runtest_2.py index fda7282..a69951b 100644 --- a/client/tests/kvm_runtest_2/kvm_runtest_2.py +++ b/client/tests/kvm_runtest_2/kvm_runtest_2.py @@ -64,7 +64,7 @@ class kvm_runtest_2(test.test): self.write_test_keyval({key: params[key]}) # Open the environment file - env_filename = os.path.join(self.bindir, "env") + env_filename = os.path.join(self.bindir, params.get("env", "env")) env = shelve.open(env_filename, writeback=True) kvm_log.debug("Contents of environment: %s" % str(env))