Re: [PATCH v2 1/3] selftests/tc-testing: add exit code

From: Davide Caratti
Date: Wed Nov 17 2021 - 03:55:27 EST


hi Li,

On Wed, Nov 17, 2021 at 01:45:15PM +0800, Li Zhijian wrote:
> Mark the summary result as FAIL to prevent from confusing the selftest
> framework if some of them are failed.
>
> Previously, the selftest framework always treats it as *ok* even though
> some of them are failed actually. That's because the script tdc.sh always
> return 0.

yes, also tdc was lacking support for KSFT_SKIP for a long time.

>
> # All test results:
> #
> # 1..97
> # ok 1 83be - Create FQ-PIE with invalid number of flows
> # ok 2 8b6e - Create RED with no flags
> [...snip]
> # ok 6 5f15 - Create RED with flags ECN, harddrop
> # ok 7 53e8 - Create RED with flags ECN, nodrop
> # ok 8 d091 - Fail to create RED with only nodrop flag
> # ok 9 af8e - Create RED with flags ECN, nodrop, harddrop
> # not ok 10 ce7d - Add mq Qdisc to multi-queue device (4 queues)
> # Could not match regex pattern. Verify command output:
> # qdisc mq 1: root
> # qdisc fq_codel 0: parent 1:4 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 32Mb ecn drop_batch 64
> # qdisc fq_codel 0: parent 1:3 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 32Mb ecn drop_batch 64
> [...snip]
> # ok 96 6979 - Change quantum of a strict ETS band
> # ok 97 9a7d - Change ETS strict band without quantum
> #
> #
> #
> #
> ok 1 selftests: tc-testing: tdc.sh <<< summary result
>
> CC: Philip Li <philip.li@xxxxxxxxx>
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Signed-off-by: Li Zhijian <zhijianx.li@xxxxxxxxx>

Looks good to me!

Acked-by: Davide Caratti <dcaratti@xxxxxxxxxx>