On 25/05/2024 15:01, Geliang Tang wrote:
> From: Geliang Tang <tanggeliang@kylinos.cn>
>
> init or init_partial may fail sometimes, in that case, titles shouldn't
> be printed out.
>
> For example, these errors occur when invalid name is set to setup_ns:
>
> 001 no JOIN
> Failed to setup namespace 'ns_temp': invalid name
>
> "001 no JOIN" shouldn't be printed out in this case.
Why? For me, it sounds better to print the title before creating the
netns: each subtest creates a new netns, that's part of the test, it is
important to know which one had an issue. Imagine there is an error later:
001 no JOIN
syn [ OK ]
synack [ OK ]
ack [ OK ]
002 single subflow, limited by client
mount --make-shared /run/netns failed: Operation not permitted
Failed to create namespace ns0
Here, it is clear the issue is when creating a new netns with the 2nd
test, that's not linked to the first one, no?
Cheers,
Matt
--
Sponsored by the NGI0 Core fund.