From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-14.4 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B0E9FC432C0 for ; Tue, 3 Dec 2019 06:41:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 82BCA2073C for ; Tue, 3 Dec 2019 06:41:02 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="mQgWYUsa" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727213AbfLCGlC (ORCPT ); Tue, 3 Dec 2019 01:41:02 -0500 Received: from mail-pj1-f66.google.com ([209.85.216.66]:37946 "EHLO mail-pj1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727223AbfLCGlC (ORCPT ); Tue, 3 Dec 2019 01:41:02 -0500 Received: by mail-pj1-f66.google.com with SMTP id l4so1108582pjt.5 for ; Mon, 02 Dec 2019 22:41:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=txqB93EC07vnRxRZaCApt0VS2Bxm0RCf+BrdUWlZ5n8=; b=mQgWYUsazi3iLKeYXps0csdlVmrHlYsQ8PPJW+N+TvkqBxRZLF3r9hThklk0JAeT/E 95g4K9LXGYqaiyl3PMjAA8hEHNCwh0BHK3lCTFehF1JZCKBWQHbkK6vJgg494kuCoDG0 llgHa+eD0gQ3/JVO/nYpmFM2RtR0AE9/LCgiwjx4ateE5sRsltCWYyijqdVXbwi+HRes vAHJESd5WrwgpkCCzoDg870kMIk27sNmUhT66e6ZAP2rm/l3UZyLLgaVD9YwyJnpCc/5 27YtK8VqP5y5D1N+TabQGA+Y7kir+ClhGf7zWb5Uesoh0JkPs0xH/jNkTmocqNFHv3Oy ZduA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=txqB93EC07vnRxRZaCApt0VS2Bxm0RCf+BrdUWlZ5n8=; b=B82GnIw5Fw21vP1xgL7BKBPlLENcHl2XskvqDiwzBQxsH+EbnCi+no47Dbn/rW6lPd 9/9Sn4sWSSQg0PqbXKhqO37/gjzcx0F6kpq42uE0iM+xGPzTStxzAix5+LjxkZ4FtOKt r96hAjpvHhtl89PMf0DpMl5MscBwig3VY5sclUe9aOUjvTuV7V8uK5krKcA+eyfDC3/I 9bZlT5CTQ34V0c06RgF1pvUlbcqJby3w0xfjS6PCvz+VPWOWNXIrFw0dum6OTdDvPjrL 5TYyow+y5yelkXBa3tN9upCU5zQQEX/zAW4nTt36ge4/+qM259Py0qGYlVM1tUdq+c1I libg== X-Gm-Message-State: APjAAAUMHunEq5rX7qP2IcWHRo6xyFiYEZIP+7j7q/IXL07FGyEM7f5K ZWmE8JZ4qpNWBb1E7cY5PgiG5YBeA68URnk8BpF7Jg== X-Google-Smtp-Source: APXvYqxFV1COUKvWUrh7FKcPNPvAl5pzHEfFxQVmduhIljm7Zx5aez1Zqxp7kxFQPcnSN/a6hmWpDnEap+IdDr9XjLE= X-Received: by 2002:a17:902:9f98:: with SMTP id g24mr3446029plq.325.1575355260934; Mon, 02 Dec 2019 22:41:00 -0800 (PST) MIME-Version: 1.0 References: <1575242724-4937-1-git-send-email-sj38.park@gmail.com> <1575242724-4937-5-git-send-email-sj38.park@gmail.com> In-Reply-To: <1575242724-4937-5-git-send-email-sj38.park@gmail.com> From: Brendan Higgins Date: Mon, 2 Dec 2019 22:40:49 -0800 Message-ID: Subject: Re: [PATCH 4/6] kunit: Create default config in 'build_dir' To: SeongJae Park Cc: shuah , Jonathan Corbet , "open list:KERNEL SELFTEST FRAMEWORK" , KUnit Development , "open list:DOCUMENTATION" , Linux Kernel Mailing List , SeongJae Park Content-Type: text/plain; charset="UTF-8" Sender: linux-kselftest-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org On Sun, Dec 1, 2019 at 3:25 PM SeongJae Park wrote: > > From: SeongJae Park > > If both '--build_dir' and '--defconfig' are given, the handling of > '--defconfig' ignores '--build_dir' option. This commit modifies the > behavior to respect '--build_dir' option. > > Signed-off-by: SeongJae Park > --- > tools/testing/kunit/kunit.py | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/tools/testing/kunit/kunit.py b/tools/testing/kunit/kunit.py > index f8f2695..1746330 100755 > --- a/tools/testing/kunit/kunit.py > +++ b/tools/testing/kunit/kunit.py > @@ -114,6 +114,11 @@ def main(argv, linux=None): > cli_args = parser.parse_args(argv) > > if cli_args.subcommand == 'run': > + if cli_args.build_dir: > + kunit_kernel.KUNITCONFIG_PATH = os.path.join( If you are going to modify the value of KUNITCONFIG_PATH can you rename the variable to make it lower_snake_case? UPPER_SNAKE_CASE in Python is usually (at least in this directory) used to indicate the variable is a constant. > + cli_args.build_dir, > + kunit_kernel.KUNITCONFIG_PATH) > + > if cli_args.defconfig: > create_default_kunitconfig() > > -- > 2.7.4 >