On Mon, Mar 24, 2025 at 10:35:13AM -0400, Stefan Berger wrote: > > > On 3/24/25 10:29 AM, Vladimir 'phcoder' Serbinenko wrote: > > Is there a risk here of missing the failures? It's common that no one > > looks at the output unless it causes a failed build on some CI/CD Le > > Good point. Maybe the test script should return '1' when a single error > occurred but run all tests nevertheless? > Sounds a good idea. At least the tester could get noticed by the return value immmediately. I'll improve the test script in the next version.
Gary Lin > > ven. 21 mars 2025, 11: 01, Gary Lin via Grub-devel <grub-devel@ gnu. > > org> a écrit : Reset 'ret' > > > > Is there a risk here of missing the failures? It's common that no one > > looks at the output unless it causes a failed build on some CI/CD > > > > Le ven. 21 mars 2025, 11:01, Gary Lin via Grub-devel <grub-devel@gnu.org > > <mailto:grub-devel@gnu.org>> a écrit : > > > > Reset 'ret' to 0 when a test case fails so that the other test cases > > could continue. > > > > Signed-off-by: Gary Lin <g...@suse.com <mailto:g...@suse.com>> > > --- > > tests/tpm2_key_protector_test.in <http:// > > tpm2_key_protector_test.in> | 2 ++ > > 1 file changed, 2 insertions(+) > > > > diff --git a/tests/tpm2_key_protector_test.in <http:// > > tpm2_key_protector_test.in> b/tests/tpm2_key_protector_test.in > > <http://tpm2_key_protector_test.in> > > index 07477ba2a..0d1115e02 100644 > > --- a/tests/tpm2_key_protector_test.in <http:// > > tpm2_key_protector_test.in> > > +++ b/tests/tpm2_key_protector_test.in <http:// > > tpm2_key_protector_test.in> > > @@ -291,6 +291,7 @@ for i in "${!srktests[@]}"; do > > echo "TPM2 [${srktests[$i]}]: PASS" > > elif [ "${ret}" -eq 1 ]; then > > echo "TPM2 [${srktests[$i]}]: FAIL" > > + ret=0 > > else > > echo "Unexpected failure [${srktests[$i]}]" >&2 > > exit ${ret} > > @@ -303,6 +304,7 @@ if [ "${ret}" -eq 0 ]; then > > echo "TPM2 [NV Index]: PASS" > > elif [ "${ret}" -eq 1 ]; then > > echo "TPM2 [NV Index]: FAIL" > > + ret=0 > > else > > echo "Unexpected failure [NV index]" >&2 > > exit ${ret} > > -- 2.43.0 > > > > > > _______________________________________________ > > Grub-devel mailing list > > Grub-devel@gnu.org <mailto:Grub-devel@gnu.org> > > https://lists.gnu.org/mailman/listinfo/grub-devel <https:// > > lists.gnu.org/mailman/listinfo/grub-devel> > > > _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel