2024-03-07 11:31:58

by Ricardo B. Marliere

[permalink] [raw]
Subject: [PATCH] ktest: force $buildonly = 1 for 'make_warnings_file' test type

The test type "make_warnings_file" should have no mandatory configuration
parameters other than the ones required by the "build" test type, because
its purpose is to create a file with build warnings that may or may not be
used by other subsequent tests. Currently, the only way to use it as a
stand-alone test is by setting POWER_CYCLE, CONSOLE, SSH_USER,
BUILD_TARGET, TARGET_IMAGE, REBOOT_TYPE and GRUB_MENU.

Signed-off-by: Ricardo B. Marliere <[email protected]>
---
tools/testing/ktest/ktest.pl | 1 +
1 file changed, 1 insertion(+)

diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl
index 829f5bdfd2e4..ab4bf87ba991 100755
--- a/tools/testing/ktest/ktest.pl
+++ b/tools/testing/ktest/ktest.pl
@@ -843,6 +843,7 @@ sub set_value {
if ($lvalue =~ /^(TEST|BISECT|CONFIG_BISECT)_TYPE(\[.*\])?$/ &&
$prvalue !~ /^(config_|)bisect$/ &&
$prvalue !~ /^build$/ &&
+ $prvalue !~ /^make_warnings_file/ &&
$buildonly) {

# Note if a test is something other than build, then we

---
base-commit: 7e90b5c295ec1e47c8ad865429f046970c549a66
change-id: 20240305-ktest-9e4452112c93

Best regards,
--
Ricardo B. Marliere <[email protected]>



2024-03-15 15:22:20

by Steven Rostedt

[permalink] [raw]
Subject: Re: [PATCH] ktest: force $buildonly = 1 for 'make_warnings_file' test type

On Tue, 05 Mar 2024 14:02:47 -0300
"Ricardo B. Marliere" <[email protected]> wrote:

> The test type "make_warnings_file" should have no mandatory configuration
> parameters other than the ones required by the "build" test type, because
> its purpose is to create a file with build warnings that may or may not be
> used by other subsequent tests. Currently, the only way to use it as a
> stand-alone test is by setting POWER_CYCLE, CONSOLE, SSH_USER,
> BUILD_TARGET, TARGET_IMAGE, REBOOT_TYPE and GRUB_MENU.

Ug, I almost forgot this patch.

>
> Signed-off-by: Ricardo B. Marliere <[email protected]>
> ---
> tools/testing/ktest/ktest.pl | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl
> index 829f5bdfd2e4..ab4bf87ba991 100755
> --- a/tools/testing/ktest/ktest.pl
> +++ b/tools/testing/ktest/ktest.pl
> @@ -843,6 +843,7 @@ sub set_value {
> if ($lvalue =~ /^(TEST|BISECT|CONFIG_BISECT)_TYPE(\[.*\])?$/ &&
> $prvalue !~ /^(config_|)bisect$/ &&
> $prvalue !~ /^build$/ &&
> + $prvalue !~ /^make_warnings_file/ &&

I think the above needs to be:

$prvalue !~ /^make_warnings_file$/ &&

Can you quickly send a v2? I'll try to get it in this merge window.

Thanks,

-- Steve


> $buildonly) {
>
> # Note if a test is something other than build, then we
>
> ---
> base-commit: 7e90b5c295ec1e47c8ad865429f046970c549a66
> change-id: 20240305-ktest-9e4452112c93
>
> Best regards,


2024-03-15 15:24:33

by Ricardo B. Marliere

[permalink] [raw]
Subject: Re: [PATCH] ktest: force $buildonly = 1 for 'make_warnings_file' test type

On 15 Mar 11:22, Steven Rostedt wrote:
> On Tue, 05 Mar 2024 14:02:47 -0300
> "Ricardo B. Marliere" <[email protected]> wrote:
>
> > The test type "make_warnings_file" should have no mandatory configuration
> > parameters other than the ones required by the "build" test type, because
> > its purpose is to create a file with build warnings that may or may not be
> > used by other subsequent tests. Currently, the only way to use it as a
> > stand-alone test is by setting POWER_CYCLE, CONSOLE, SSH_USER,
> > BUILD_TARGET, TARGET_IMAGE, REBOOT_TYPE and GRUB_MENU.
>
> Ug, I almost forgot this patch.
>
> >
> > Signed-off-by: Ricardo B. Marliere <[email protected]>
> > ---
> > tools/testing/ktest/ktest.pl | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl
> > index 829f5bdfd2e4..ab4bf87ba991 100755
> > --- a/tools/testing/ktest/ktest.pl
> > +++ b/tools/testing/ktest/ktest.pl
> > @@ -843,6 +843,7 @@ sub set_value {
> > if ($lvalue =~ /^(TEST|BISECT|CONFIG_BISECT)_TYPE(\[.*\])?$/ &&
> > $prvalue !~ /^(config_|)bisect$/ &&
> > $prvalue !~ /^build$/ &&
> > + $prvalue !~ /^make_warnings_file/ &&
>
> I think the above needs to be:
>
> $prvalue !~ /^make_warnings_file$/ &&
>
> Can you quickly send a v2? I'll try to get it in this merge window.

Hi Steve,

Thanks for the review, I'll send a v2 now.
- Ricardo


>
> Thanks,
>
> -- Steve
>
>
> > $buildonly) {
> >
> > # Note if a test is something other than build, then we
> >
> > ---
> > base-commit: 7e90b5c295ec1e47c8ad865429f046970c549a66
> > change-id: 20240305-ktest-9e4452112c93
> >
> > Best regards,
>