[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aRvdb65MyVc39nm6@fedora>
Date: Tue, 18 Nov 2025 02:43:59 +0000
From: Hangbin Liu <liuhangbin@...il.com>
To: Matthieu Baerts <matttbe@...nel.org>
Cc: netdev@...r.kernel.org, Donald Hunter <donald.hunter@...il.com>,
Jakub Kicinski <kuba@...nel.org>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>, Paolo Abeni <pabeni@...hat.com>,
Simon Horman <horms@...nel.org>, Jan Stancek <jstancek@...hat.com>,
Asbjørn Sloth Tønnesen <ast@...erby.net>,
Stanislav Fomichev <sdf@...ichev.me>,
Ido Schimmel <idosch@...dia.com>,
Guillaume Nault <gnault@...hat.com>,
Sabrina Dubroca <sd@...asysnail.net>,
Petr Machata <petrm@...dia.com>
Subject: Re: [PATCHv5 net-next 3/3] tools: ynl: add YNL test framework
On Tue, Nov 18, 2025 at 03:21:35AM +0100, Matthieu Baerts wrote:
> 18 Nov 2025 02:15:08 Hangbin Liu <liuhangbin@...il.com>:
>
> > On Mon, Nov 17, 2025 at 11:59:32AM +0100, Matthieu Baerts wrote:
> >> I just have one question below, but that's not blocking.
> >>
> >> (...)
> >>
> >>> diff --git a/tools/net/ynl/tests/test_ynl_cli.sh b/tools/net/ynl/tests/test_ynl_cli.sh
> >>> new file mode 100755
> >>> index 000000000000..cccab336e9a6
> >>> --- /dev/null
> >>> +++ b/tools/net/ynl/tests/test_ynl_cli.sh
> >>> @@ -0,0 +1,327 @@
> >>> +#!/bin/bash
> >>> +# SPDX-License-Identifier: GPL-2.0
> >>> +# Test YNL CLI functionality
> >>> +
> >>> +# Load KTAP test helpers
> >>> +KSELFTEST_KTAP_HELPERS="$(dirname "$(realpath "$0")")/../../../testing/selftests/kselftest/ktap_helpers.sh"
> >>> +# shellcheck source=/dev/null
> >>
> >> Out of curiosity, why did you put source=/dev/null? It is equivalent to
> >> "disable=SC1090" and there is no comment explaining why: was it not OK
> >> to use this?
> >>
> >> shellcheck source=../../../testing/selftests/kselftest/ktap_helpers.sh
> >>
> >
> > I got the following warning with it
> >
> > In test_ynl_cli.sh line 8:
> > source "$KSELFTEST_KTAP_HELPERS"
> > ^-----------------------^ SC1091 (info): Not following: ../../../testing/selftests/kselftest/ktap_helpers.sh was not specified as input (see shellcheck -x).
>
> How did you execute shellcheck?
>
> If I'm not mistaken, you are supposed to execute it from the same directory, and with -x:
>
> cd "$(dirname "${script}")"
> shellcheck -x "$(basename "${script}")"
Ah, I forgot to add the "-x" option... I will fix the comment in future test
case update.
Thanks
Hangbin
Powered by blists - more mailing lists