lkml.org 
[lkml]   [2021]   [May]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v5 2/2] selftests/sgx: Migrate to kselftest harness
From
Date
Hi Jarkko,

On 5/12/2021 2:53 PM, Jarkko Sakkinen wrote:
> Migrate to kselftest harness. Use a fixture test with enclave initialized
> and de-initialized for each of the existing three tests, in other words:
>
> 1. One FIXTURE() for managing the enclave life-cycle.
> 2. Three TEST_F()'s, one for each test case.
>
> This gives a leaps better reporting than before. Here's an example
> transcript:
>
> TAP version 13
> 1..3
>
> ok 1 enclave.unclobbered_vdso
>
> ok 2 enclave.clobbered_vdso
>
> ok 3 enclave.clobbered_vdso_and_user_function
>
> Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
> ---
>
> v5:
> * Use TH_LOG() for printing enclave address ranges instead of printf(),
> based on Reinette's remark.

Thank you for considering my feedback. The motivation for my comment was
to consider how this test output will be parsed. If these tests will
have their output parsed by automated systems then it needs to conform
to the TAP13 format as supported by kselftest.

In your latest version the output printed during a successful test has
been changed, using TH_LOG() as you noted. From what I can tell this is
the only output addressed - failing tests continue to print error
messages (perror, fprintf) without consideration of how they will be
parsed. My apologies, I am not a kselftest expert to know what the best
way for this integration is.

Reinette

\
 
 \ /
  Last update: 2021-05-17 19:04    [W:0.088 / U:0.452 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site