lkml.org 
[lkml]   [2020]   [Mar]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v7 kunit-next 3/4] kunit: subtests should be indented 4 spaces according to TAP
From
Date
On 3/13/20 8:44 AM, Alan Maguire wrote:
> Introduce KUNIT_INDENT macro which corresponds to 4-space indentation,
> and use it to modify indentation from tab to 4 spaces.
>
> Suggested-by: Frank Rowand <frowand.list@gmail.com>
> Signed-off-by: Alan Maguire <alan.maguire@oracle.com>
> Reviewed-by: Frank Rowand <frank.rowand@sony.com>
> ---
> include/kunit/test.h | 7 +++-
> lib/kunit/assert.c | 79 +++++++++++++++++++------------------
> lib/kunit/test.c | 6 +--
> tools/testing/kunit/kunit_parser.py | 10 ++---
> 4 files changed, 54 insertions(+), 48 deletions(-)
>
> diff --git a/include/kunit/test.h b/include/kunit/test.h
> index f7b2ed4c..d49cdb4 100644
> --- a/include/kunit/test.h
> +++ b/include/kunit/test.h
> @@ -84,6 +84,10 @@ struct kunit_resource {
> /* Size of log associated with test. */
> #define KUNIT_LOG_SIZE 512
>
> +/* TAP specifies subtest indentation of 4 spaces. */
> +#define KUNIT_INDENT " "
> +#define KUNIT_INDENT2 KUNIT_INDENT KUNIT_INDENT

Sorry for a late comment on this.

What's the reason to do it this way? Why wouldn't you define
it as 8 spaces long string?

Also can you please make sure to run checkpatch --strict on the
patches you send?

thanks,
-- Shuah

\
 
 \ /
  Last update: 2020-03-25 21:06    [W:0.058 / U:4.800 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site