From patchwork Tue Aug 3 13:44:23 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lucas Meneghel Rodrigues X-Patchwork-Id: 116770 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o73DirqA030159 for ; Tue, 3 Aug 2010 13:44:53 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756593Ab0HCNod (ORCPT ); Tue, 3 Aug 2010 09:44:33 -0400 Received: from mx1.redhat.com ([209.132.183.28]:47065 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756522Ab0HCNoa (ORCPT ); Tue, 3 Aug 2010 09:44:30 -0400 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o73DiSJi011408 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 3 Aug 2010 09:44:28 -0400 Received: from freedom.redhat.com (vpn-10-190.rdu.redhat.com [10.11.10.190]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o73DiPAS032723; Tue, 3 Aug 2010 09:44:26 -0400 From: Lucas Meneghel Rodrigues To: autotest@test.kernel.org Cc: kvm@vger.kernel.org, avi@redhat.com, Lucas Meneghel Rodrigues Subject: [PATCH] KVM test: Unittest subtest: Avoid leak of extra_params Date: Tue, 3 Aug 2010 10:44:23 -0300 Message-Id: <1280843063-3998-1-git-send-email-lmr@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.18 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Tue, 03 Aug 2010 13:44:53 +0000 (UTC) diff --git a/client/tests/kvm/tests/unittest.py b/client/tests/kvm/tests/unittest.py index ad95720..c52637a 100644 --- a/client/tests/kvm/tests/unittest.py +++ b/client/tests/kvm/tests/unittest.py @@ -46,6 +46,8 @@ def run_unittest(test, params, env): timeout = int(params.get('unittest_timeout', 600)) + extra_params_original = params['extra_params'] + for t in test_list: logging.info('Running %s', t) @@ -111,5 +113,8 @@ def run_unittest(test, params, env): except NameError, IOError: logging.error("Not possible to collect logs") + # Restore the extra params so other tests can run normally + params['extra_params'] = extra_params_original + if nfail != 0: raise error.TestFail("Unit tests failed: %s" % " ".join(tests_failed))