Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp106201imb; Thu, 28 Feb 2019 17:34:15 -0800 (PST) X-Google-Smtp-Source: APXvYqz5ZlTvrlCth+vi/xYPTu6bRMqEk2vhlnD0d9CR+cX2Qlzki2lF/Qc9PW1cH2q+MTdWIdqe X-Received: by 2002:a63:a41:: with SMTP id z1mr2213553pgk.117.1551404055531; Thu, 28 Feb 2019 17:34:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551404055; cv=none; d=google.com; s=arc-20160816; b=PgbdiTgdZsK2bIaHtWCY3jUjDSpfuFvz4td2JTZ8opxo1zf6cpK9NyWzmC2kcvtyo9 2wG7LOoSsjNrKHjGwHZGRg1+L4R6wggWV4yHmnahKqI1xE/LCZMBqUw2QukfoMvqn0eN ZkdVucn6ctvSkKeecX/iM9owk2fbgiSxXg1E8nd90pbKnFop2RbymZfMVFJH0UXCTsZN XNApo8RDPFysAkaWVBwhUhkgRPVrbXybJVdSXY6vWI8x/jDcDWz49A5MoVVNtUMeF4xf XLcoa90Vi/H6JxQQqLb1QOITRDmjOxWQHspoWlLdblFyn3m50RkFp4806NxuvCkqIAoO fF/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:reply-to:message-id :subject:cc:to:from:date; bh=MqMAlHMPhGekiy31lgoG3YFcZGVcabYAyC6SSQPVHAM=; b=ROJN87Zw1E2WFXqVHuxzvkvpZTFb2QSG/C6Fywln9V2xhDyuXMJgLBdGHZarXUN1QI FNfBm+S46OHtsHRhx0XISfosJOTaDvuk+qEn2YbpFS/aCj1h184BN/KytZ9vMMZ7I2yA sxX4g4bpEN1z+5CAMt0X3gaAOubC+pF7lEMlhId6LPcbEaxB+tokCrMCi8dwN+QMNTLd oIqvpoml3qpNtkoT42Qd7XWMJEzfQHMW8ZtTOlKvkHnMiwj837ppHjiAB1+KjFI9fdxD UNpEH3ikKoYi9W78ovsHeryrsJvaRZBjKxYrH0p5VT6LAInU7auEZcFejniN+Nyg+0rQ ys3w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y142si20802672pfb.149.2019.02.28.17.34.00; Thu, 28 Feb 2019 17:34:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731890AbfB1XOr (ORCPT + 99 others); Thu, 28 Feb 2019 18:14:47 -0500 Received: from mx2.suse.de ([195.135.220.15]:36732 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1732702AbfB1XOo (ORCPT ); Thu, 28 Feb 2019 18:14:44 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id D3CE1ABA1; Thu, 28 Feb 2019 23:14:42 +0000 (UTC) Date: Fri, 1 Mar 2019 00:14:41 +0100 From: Petr Vorel To: shuah Cc: Mimi Zohar , linux-kselftest@vger.kernel.org, linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 5/5] selftests/ima: loading kernel modules Message-ID: <20190228231441.GF20335@dell5510> Reply-To: Petr Vorel References: <1551223620-11586-1-git-send-email-zohar@linux.ibm.com> <1551223620-11586-6-git-send-email-zohar@linux.ibm.com> <19d494c6-ecb1-b884-2d23-5f556b3ec05b@kernel.org> <1551276893.10911.23.camel@linux.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.11.3 (2019-02-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Shuah, > We can do this as a separate effort in the interest of getting these > in the interest of getting these in. > We have common functions in ksefltest.h for c and we don't have them > for tests scripts. We might be able to collect common routines such > as get_kconfig into a common .sh and include in tests. If you have time > to do this, that will be great. It can be done as a separate effort. Some inspiration, what sort of helpers can be for shell see LTP shell API [1]. These helpers tests help tests to be short, readable and with unified output. (I like library variables [2] which are self describing and making test even shorter), setup and cleanup functions called automatically, ... The same applies for C API [3] (e.g. SAFE_*() helpers for handling errors, ...). I wonder if there is even any interest of having any sort of helpers or even framework for shell, when so far there was nothing. > thanks, > -- Shuah Kind regards, Petr [1] https://github.com/linux-test-project/ltp/wiki/Test-Writing-Guidelines#23-writing-a-testcase-in-shell [2] https://github.com/linux-test-project/ltp/wiki/Test-Writing-Guidelines#232-library-variables [3] https://github.com/linux-test-project/ltp/wiki/Test-Writing-Guidelines#22-writing-a-test-in-c