Subject: Re: [patch net-next v2 2/2] selftests: netdevsim: add devlink params tests

From: Jiri Pirko <[email-masked]>
Date: Thu, 15 Aug 2019 07:58:29 +0200

Thu, Aug 15, 2019 at 03:09:00AM CEST, [email-masked] wrote:
>On Wed, 14 Aug 2019 17:26:04 +0200, Jiri Pirko wrote:
>> From: Jiri Pirko <[email-masked]>
>> 
>> Test recently added netdevsim devlink param implementation.
>> 
>> Signed-off-by: Jiri Pirko <[email-masked]>
>> ---
>> v1->v2:
>> -using cmd_jq helper
>
>Still failing here :(

Ugh :/

>
># ./devlink.sh 
>TEST: fw flash test                                                 [ OK ]
>TEST: params test                                                   [FAIL]
>	Failed to get test1 param value
>TEST: regions test                                                  [ OK ]
>
># jq --version
>jq-1.5-1-a5b5cbe
># echo '{ "a" : false }' | jq -e -r '.[]'
>false
># echo $?
>1
>
>On another machine:
>
>$ echo '{ "a" : false }' | jq -e -r '.[]'
>false
>$ echo $?
>1
>
>Did you mean to drop the -e ?

No. -e is needed in order to jq return error in case there is no output.
Looks like a bug in jq 1.6 fixed. How about I add a check for jq >= 1.6?