From patchwork Mon Sep 25 17:57:29 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Wajdeczko X-Patchwork-Id: 726872 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AE9BCCE7AB3 for ; Mon, 25 Sep 2023 17:58:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231263AbjIYR6J (ORCPT ); Mon, 25 Sep 2023 13:58:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37370 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232548AbjIYR6G (ORCPT ); Mon, 25 Sep 2023 13:58:06 -0400 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9187E19E for ; Mon, 25 Sep 2023 10:57:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1695664677; x=1727200677; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=FNtO6GAEV5vAdrVcg9C+rRwuTzaz5sN93qtjUy9BdYc=; b=SH5yx1Cr9Z9O6MHVNAgg1/RQRbbNc/p4JPYJ2xCeGN+cuIExXULBAa8a NCMrV63Ub1NXWx76a+kTgQXEbNvc0e96pI0sPKpbpFMg5lye2W+LZE6sg LZFVDZuKt/76T2Q9gaY1FNuHcyZ6DdlLW+CqVCu9BXhPq8xzKeQLZ4bWU MqaqmHR2ljE29JYlhXsEcdQ/VRYzVyhBsSHPWzccryXCEK6IkNJjku//c QrG65aeVlScN2skFGgFhpMXlwDcQzWtkaMqdsp0fBKODpbGySHzWzQtjn U1SCvPcWhbV5K04FAkLJJeEReWM8FRhdliH0TknQpCeMuWbrlbJOnx7KV A==; X-IronPort-AV: E=McAfee;i="6600,9927,10843"; a="371643638" X-IronPort-AV: E=Sophos;i="6.03,175,1694761200"; d="scan'208";a="371643638" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Sep 2023 10:57:54 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10843"; a="995489251" X-IronPort-AV: E=Sophos;i="6.03,175,1694761200"; d="scan'208";a="995489251" Received: from mwajdecz-mobl.ger.corp.intel.com ([10.249.131.28]) by fmsmga006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Sep 2023 10:57:52 -0700 From: Michal Wajdeczko To: linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com Cc: Michal Wajdeczko , David Gow , Rae Moar Subject: [PATCH 0/4] kunit: Fix indentation of parameterized tests messages Date: Mon, 25 Sep 2023 19:57:29 +0200 Message-Id: <20230925175733.1379-1-michal.wajdeczko@intel.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-kselftest@vger.kernel.org The indentation of parameterized tests messages is currently broken in kunit. Try to fix that by introducing a test level attribute, that will be increased during nested parameterized tests execution, and use it to generate correct indent at the runtime when printing message or writing them to the log. Also improve kunit by providing test plan for the parameterized tests. Cc: David Gow Cc: Rae Moar Michal Wajdeczko (4): kunit: Drop redundant text from suite init failure message kunit: Fix indentation level of suite messages kunit: Fix indentation of parameterized tests messages kunit: Prepare test plan for parameterized subtests include/kunit/test.h | 25 ++++++++++++-- lib/kunit/test.c | 79 +++++++++++++++++++++++--------------------- 2 files changed, 65 insertions(+), 39 deletions(-)