<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/test/hush, branch v2026.04</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>global: Avoid indirect inclusion of &lt;env.h&gt; from &lt;command.h&gt;</title>
<updated>2025-05-29T14:29:16+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2025-05-14T22:46:03+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=dcb7d927d181b5798c6fd4a1b1650cd821e3b6ed'/>
<id>dcb7d927d181b5798c6fd4a1b1650cd821e3b6ed</id>
<content type='text'>
The include file &lt;command.h&gt; does not need anything from &lt;env.h&gt;.
Furthermore, include/env.h itself includes other headers which can lead
to longer indirect inclusion paths. To prepare to remove &lt;env.h&gt; from
&lt;command.h&gt; fix all of the places which had relied on this indirect
inclusion to instead include &lt;env.h&gt; directly.

Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@kernel.org&gt; # android, bcb
Reviewed-by: Jerome Forissier &lt;jerome.forissier@linaro.org&gt; # spawn
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The include file &lt;command.h&gt; does not need anything from &lt;env.h&gt;.
Furthermore, include/env.h itself includes other headers which can lead
to longer indirect inclusion paths. To prepare to remove &lt;env.h&gt; from
&lt;command.h&gt; fix all of the places which had relied on this indirect
inclusion to instead include &lt;env.h&gt; directly.

Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@kernel.org&gt; # android, bcb
Reviewed-by: Jerome Forissier &lt;jerome.forissier@linaro.org&gt; # spawn
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: Drop the function for running hush tests</title>
<updated>2025-01-24T20:34:40+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2025-01-20T21:25:51+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=d5e5cb48e646ef089b57a4d924796b153f73fbfd'/>
<id>d5e5cb48e646ef089b57a4d924796b153f73fbfd</id>
<content type='text'>
Use the new suite-runner to run these tests instead.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use the new suite-runner to run these tests instead.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: Drop the _test suffix on linker lists</title>
<updated>2025-01-24T20:34:40+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2025-01-20T21:25:32+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=4ba3ab4901c564725c37e927e2ba29595712cd9d'/>
<id>4ba3ab4901c564725c37e927e2ba29595712cd9d</id>
<content type='text'>
Most test suites have a _test suffix. This is not necessary as there is
also a ut_ prefix.

Drop the suffix so that (with future work) the suite name can be used as
the linker-list name.

Remove the suffix from the pytest regex as well, moving it to the top of
the file, as it is a constant.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Most test suites have a _test suffix. This is not necessary as there is
also a ut_ prefix.

Drop the suffix so that (with future work) the suite name can be used as
the linker-list name.

Remove the suffix from the pytest regex as well, moving it to the top of
the file, as it is a constant.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: Add newlines to hush-test messages</title>
<updated>2025-01-24T20:34:40+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2025-01-20T21:25:28+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=ea2bb8e20f9759f98db93b24728ed478f06dc875'/>
<id>ea2bb8e20f9759f98db93b24728ed478f06dc875</id>
<content type='text'>
A few messages lack a newline so the test output shows the next
test-name on the same line. For example:

   Beware: this test sets local variable dollar_bar and dollar_quux
      and they cannot be unset!Test: hush_test_env_dollar: dollar.c

This is confusing, so fix it.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A few messages lack a newline so the test output shows the next
test-name on the same line. For example:

   Beware: this test sets local variable dollar_bar and dollar_quux
      and they cannot be unset!Test: hush_test_env_dollar: dollar.c

This is confusing, so fix it.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test/hush: Add CONFIG_CONSOLE_RECORD where required</title>
<updated>2024-10-29T22:17:47+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2024-10-28T16:48:43+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=2d42f7d9018a9c7bf7e65780d6505280a46c0cda'/>
<id>2d42f7d9018a9c7bf7e65780d6505280a46c0cda</id>
<content type='text'>
The "dollar" tests require CONFIG_CONSOLE_RECORD to be enabled so guard
with that.

Reviewed-by: Heinrich Schuchardt &lt;xypron.glpk@gmx.de&gt;
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The "dollar" tests require CONFIG_CONSOLE_RECORD to be enabled so guard
with that.

Reviewed-by: Heinrich Schuchardt &lt;xypron.glpk@gmx.de&gt;
Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge patch series "Bump new hush commits and fix old hush test behavior"</title>
<updated>2024-09-13T19:44:00+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2024-09-13T19:44:00+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=979207ed6bac1b148802abb85750fc5e9cea223e'/>
<id>979207ed6bac1b148802abb85750fc5e9cea223e</id>
<content type='text'>
Francis Laniel &lt;francis.laniel@amarulasolutions.com&gt; says:

Hi!

With this series, I bumped the new hush to get the latest commits from upstream.

Also, I added back a reverted commit which goal was to fix a bad behavior in
old hush test.
I had to tweak a bit this commit, but everything worked both locally and in the
CI.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Francis Laniel &lt;francis.laniel@amarulasolutions.com&gt; says:

Hi!

With this series, I bumped the new hush to get the latest commits from upstream.

Also, I added back a reverted commit which goal was to fix a bad behavior in
old hush test.
I had to tweak a bit this commit, but everything worked both locally and in the
CI.
</pre>
</div>
</content>
</entry>
<entry>
<title>test: hush: dollar: fix bugous behavior</title>
<updated>2024-09-13T19:43:56+00:00</updated>
<author>
<name>Ion Agorria</name>
<email>ion@agorria.com</email>
</author>
<published>2024-09-03T17:09:42+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=80ef176ac1ea385eefe95828da5cae4be04532f8'/>
<id>80ef176ac1ea385eefe95828da5cae4be04532f8</id>
<content type='text'>
The dollar test was merged with bugous console behavior, and
instead of fixing it, this behavior was just workarounded.
This was done to keep compatibility with the existing behavior.

It seems like without the fix the ut_assert_skipline(); didn't clear
console and running ut_assert_skipline(); many times would give always
OK. With e58bafc35fe3 ("lib: membuff: fix readline not returning line in case of overflow")
the line is cleared correctly and next assert fails because now there
is nothing to clean which is correct if we look the this a bit above
the failing assert:

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
         /*
          * For some strange reasons, the console is not empty after
          * running above command.
          * So, we reset it to not have side effects for other tests.
          */
         console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
         ut_assert_console_end();
    }

Which further confirms that tests workaround the old problem and now
that problem is fixed we can remove the whole if blocks and simply
place ut_assert_console_end() right after ut_assert_skipline() without
any conditional and will pass green.

So this part of code goes from:
    ut_assert_skipline();
    ut_assert_skipline();

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
        /* See above comments. */
        console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
        ut_assert_console_end();
    }

to become:
    ut_assert_skipline();
    if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
        ut_assert_skipline();
    }
    ut_assert_console_end();

The if block mentioned above that calls console_record_reset_enable() is
completely removed as fixed by e58bafc35fe3.

[flaniel: adapt second if]

Signed-off-by: Ion Agorria &lt;ion@agorria.com&gt;
Signed-off-by: Svyatoslav Ryhel &lt;clamor95@gmail.com&gt;
Tested-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Link: https://lore.kernel.org/r/20240105072212.6615-8-clamor95@gmail.com
[mkorpershoek: reworded commit title]
Signed-off-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
[flaniel: remove console_record_reset_enable() if]
Signed-off-by: Francis Laniel &lt;francis.laniel@amarulasolutions.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The dollar test was merged with bugous console behavior, and
instead of fixing it, this behavior was just workarounded.
This was done to keep compatibility with the existing behavior.

It seems like without the fix the ut_assert_skipline(); didn't clear
console and running ut_assert_skipline(); many times would give always
OK. With e58bafc35fe3 ("lib: membuff: fix readline not returning line in case of overflow")
the line is cleared correctly and next assert fails because now there
is nothing to clean which is correct if we look the this a bit above
the failing assert:

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
         /*
          * For some strange reasons, the console is not empty after
          * running above command.
          * So, we reset it to not have side effects for other tests.
          */
         console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
         ut_assert_console_end();
    }

Which further confirms that tests workaround the old problem and now
that problem is fixed we can remove the whole if blocks and simply
place ut_assert_console_end() right after ut_assert_skipline() without
any conditional and will pass green.

So this part of code goes from:
    ut_assert_skipline();
    ut_assert_skipline();

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
        /* See above comments. */
        console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
        ut_assert_console_end();
    }

to become:
    ut_assert_skipline();
    if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
        ut_assert_skipline();
    }
    ut_assert_console_end();

The if block mentioned above that calls console_record_reset_enable() is
completely removed as fixed by e58bafc35fe3.

[flaniel: adapt second if]

Signed-off-by: Ion Agorria &lt;ion@agorria.com&gt;
Signed-off-by: Svyatoslav Ryhel &lt;clamor95@gmail.com&gt;
Tested-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Link: https://lore.kernel.org/r/20240105072212.6615-8-clamor95@gmail.com
[mkorpershoek: reworded commit title]
Signed-off-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
[flaniel: remove console_record_reset_enable() if]
Signed-off-by: Francis Laniel &lt;francis.laniel@amarulasolutions.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: hush: Use UTF_CONSOLE in tests</title>
<updated>2024-08-27T00:51:49+00:00</updated>
<author>
<name>Simon Glass</name>
<email>sjg@chromium.org</email>
</author>
<published>2024-08-22T13:58:00+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=d77519652ab5378cef529bb0bc0846060d85a306'/>
<id>d77519652ab5378cef529bb0bc0846060d85a306</id>
<content type='text'>
Set this flag rather than doing things manually in the test.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Set this flag rather than doing things manually in the test.

Signed-off-by: Simon Glass &lt;sjg@chromium.org&gt;
Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "test: hush: dollar: fix bugous behavior"</title>
<updated>2024-01-18T16:38:25+00:00</updated>
<author>
<name>Tom Rini</name>
<email>trini@konsulko.com</email>
</author>
<published>2024-01-18T16:38:25+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=f7cca7ccc5117eaafcc2bde91ad1bed6fee7cfc3'/>
<id>f7cca7ccc5117eaafcc2bde91ad1bed6fee7cfc3</id>
<content type='text'>
What we were doing here amounts to simplifying the code for the new hush
parser, and the workarounds are required when using the old one. As we
have returned to having the old parser be default for now, we must undo
this so that the test passes again.

This reverts commit 6c2f753f4ad3dcee60190949d1286736a6d51d17.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
What we were doing here amounts to simplifying the code for the new hush
parser, and the workarounds are required when using the old one. As we
have returned to having the old parser be default for now, we must undo
this so that the test passes again.

This reverts commit 6c2f753f4ad3dcee60190949d1286736a6d51d17.

Signed-off-by: Tom Rini &lt;trini@konsulko.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>test: hush: dollar: fix bugous behavior</title>
<updated>2024-01-09T14:31:59+00:00</updated>
<author>
<name>Ion Agorria</name>
<email>ion@agorria.com</email>
</author>
<published>2024-01-05T07:22:12+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=6c2f753f4ad3dcee60190949d1286736a6d51d17'/>
<id>6c2f753f4ad3dcee60190949d1286736a6d51d17</id>
<content type='text'>
The dollar test was merged with bugous console behavior, and
instead of fixing it, this behavior was just workarounded.

It seems like without the fix the ut_assert_skipline(); didn't clear
console and running ut_assert_skipline(); many times would give always
OK. With

lib: membuff: fix readline not returning line in case of overflow

the line is cleared correctly and next assert fails because now there
is nothing to clean which is correct if we look the this a bit above
the failing assert:

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
         /*
          * For some strange reasons, the console is not empty after
          * running above command.
          * So, we reset it to not have side effects for other tests.
          */
         console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
         ut_assert_console_end();
    }

Which further confirms that tests workaround the old problem and now
that problem is fixed we can remove the whole if blocks and simply
place ut_assert_console_end() right after ut_assert_skipline() without
any conditional and will pass green.

So this part of code goes from:
    ut_assert_skipline();
    ut_assert_skipline();

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
        /* See above comments. */
        console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
        ut_assert_console_end();
    }

to become:
    ut_assert_skipline();
    ut_assert_console_end();

Same thing should be done with the if block mentioned above that calls
console_record_reset_enable().

Signed-off-by: Ion Agorria &lt;ion@agorria.com&gt;
Signed-off-by: Svyatoslav Ryhel &lt;clamor95@gmail.com&gt;
Tested-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Link: https://lore.kernel.org/r/20240105072212.6615-8-clamor95@gmail.com
[mkorpershoek: reworded commit title]
Signed-off-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The dollar test was merged with bugous console behavior, and
instead of fixing it, this behavior was just workarounded.

It seems like without the fix the ut_assert_skipline(); didn't clear
console and running ut_assert_skipline(); many times would give always
OK. With

lib: membuff: fix readline not returning line in case of overflow

the line is cleared correctly and next assert fails because now there
is nothing to clean which is correct if we look the this a bit above
the failing assert:

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
         /*
          * For some strange reasons, the console is not empty after
          * running above command.
          * So, we reset it to not have side effects for other tests.
          */
         console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
         ut_assert_console_end();
    }

Which further confirms that tests workaround the old problem and now
that problem is fixed we can remove the whole if blocks and simply
place ut_assert_console_end() right after ut_assert_skipline() without
any conditional and will pass green.

So this part of code goes from:
    ut_assert_skipline();
    ut_assert_skipline();

    if (gd-&gt;flags &amp; GD_FLG_HUSH_MODERN_PARSER) {
        /* See above comments. */
        console_record_reset_enable();
    } else if (gd-&gt;flags &amp; GD_FLG_HUSH_OLD_PARSER) {
        ut_assert_console_end();
    }

to become:
    ut_assert_skipline();
    ut_assert_console_end();

Same thing should be done with the if block mentioned above that calls
console_record_reset_enable().

Signed-off-by: Ion Agorria &lt;ion@agorria.com&gt;
Signed-off-by: Svyatoslav Ryhel &lt;clamor95@gmail.com&gt;
Tested-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Reviewed-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
Link: https://lore.kernel.org/r/20240105072212.6615-8-clamor95@gmail.com
[mkorpershoek: reworded commit title]
Signed-off-by: Mattijs Korpershoek &lt;mkorpershoek@baylibre.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
