From: Ivan Orlov <ivan.orlov0322@gmail.com>
To: Rae Moar <rmoar@google.com>
Cc: brendan.higgins@linux.dev, davidgow@google.com,
linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com,
linux-kernel@vger.kernel.org, skhan@linuxfoundation.org
Subject: Re: [PATCH] kunit: Cover 'assert.c' with tests
Date: Tue, 30 Apr 2024 10:19:09 +0100 [thread overview]
Message-ID: <fd27b640-f807-4636-bb31-1865a1f1f775@gmail.com> (raw)
In-Reply-To: <CA+GJov5Ve+NksNMXrd32p6RCPcSuf0oCZ-QA8LdhcvFWA48ukA@mail.gmail.com>
On 4/29/24 22:26, Rae Moar wrote:
> On Sat, Apr 27, 2024 at 6:04 PM Ivan Orlov <ivan.orlov0322@gmail.com> wrote:
>>
>> There are multiple assertion formatting functions in the `assert.c`
>> file, which are not covered with tests yet. Implement the KUnit test
>> for these functions.
>>
>> The test consists of 11 test cases for the following functions:
>>
>> 1) 'is_literal'
>> 2) 'is_str_literal'
>> 3) 'kunit_assert_prologue', test case for multiple assert types
>> 4) 'kunit_assert_print_msg'
>> 5) 'kunit_unary_assert_format'
>> 6) 'kunit_ptr_not_err_assert_format'
>> 7) 'kunit_binary_assert_format'
>> 8) 'kunit_binary_ptr_assert_format'
>> 9) 'kunit_binary_str_assert_format'
>> 10) 'kunit_assert_hexdump'
>> 11) 'kunit_mem_assert_format'
>>
>> The test aims at maximizing the branch coverage for the assertion
>> formatting functions. As you can see, it covers some of the static
>> helper functions as well, so we have to import the test source in the
>> `assert.c` file in order to be able to call and validate them.
>>
>> Signed-off-by: Ivan Orlov <ivan.orlov0322@gmail.com>
>
> Hello,
>
> I'll give this a full review tomorrow. But with a quick glance and
> test, this is looking good to me.
>
> Tested-by: Rae Moar <rmoar@google.com>
>
> Thanks!
> -Rae
Hi Rae,
Thanks a lot for testing the patch.
Looking forward to seeing your review! :)
--
Kind regards,
Ivan Orlov
next prev parent reply other threads:[~2024-04-30 9:19 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-27 22:04 [PATCH] kunit: Cover 'assert.c' with tests Ivan Orlov
2024-04-29 21:26 ` Rae Moar
2024-04-30 9:19 ` Ivan Orlov [this message]
2024-05-01 23:20 ` Rae Moar
2024-05-03 11:10 ` Ivan Orlov
2024-05-03 12:18 ` Ivan Orlov
2024-05-04 16:45 ` Ivan Orlov
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:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fd27b640-f807-4636-bb31-1865a1f1f775@gmail.com \
--to=ivan.orlov0322@gmail.com \
--cc=brendan.higgins@linux.dev \
--cc=davidgow@google.com \
--cc=kunit-dev@googlegroups.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=rmoar@google.com \
--cc=skhan@linuxfoundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* 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