archive mirror
 help / color / mirror / Atom feed
From: "André Almeida" <>
To: Andy Shevchenko <>
Cc: Christoph Hellwig <>,,
	Brendan Higgins <>,,,
	Shuah Khan <>,
	Vitor Massaru Iha <>,, David Gow <>,
	Daniel Latypov <>,
Subject: Re: [PATCH v3 0/1] lib: Convert UUID runtime test to KUnit
Date: Fri, 11 Jun 2021 07:48:26 -0300	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

Hi Andy,

Às 06:55 de 11/06/21, Andy Shevchenko escreveu:
> On Thu, Jun 10, 2021 at 01:39:58PM -0300, André Almeida wrote:
>> Hi,
>> This patch converts existing UUID runtime test to use KUnit framework.
>> Below, there's a comparison between the old output format and the new
>> one. Keep in mind that even if KUnit seems very verbose, this is the
>> corner case where _every_ test has failed.
> Btw, do we have test coverage statistics?
> I mean since we reduced 18 test cases to 12, do we still have the same / better
> test coverage?
I don't think we have automated statistics, but I can assure you that
the coverage it's exactly the same. We are testing two correlated
functions with the same input, in a single test case, instead of having
a single case for each one, so that's why the number of cases is reduced.

For example, instead of:

	if (guid_parse(data->uuid, &le))

	if (!guid_equal(&data->le, &le))

We now have:

	KUNIT_ASSERT_EQ(guid_parse(data->guid, &le), 0)
	KUNIT_EXPECT_TRUE(guid_equal(&data->le, &le))

That will count as a single test.

      reply	other threads:[~2021-06-11 10:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-10 16:39 [PATCH v3 0/1] lib: Convert UUID runtime test to KUnit André Almeida
2021-06-10 16:39 ` [PATCH v3 1/1] " André Almeida
2021-06-14  6:42   ` Christoph Hellwig
2021-06-14 16:55     ` Daniel Latypov
2021-06-14 21:08       ` André Almeida
2021-06-11  9:55 ` [PATCH v3 0/1] " Andy Shevchenko
2021-06-11 10:48   ` André Almeida [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
    --cc=~lkcamp/ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).