[elbe-devel] [PATCH v2 3/5] Call new junit API in project finetuning.
Torben Hohn
torben.hohn at linutronix.de
Wed Aug 7 17:27:30 CEST 2019
On Wed, Aug 07, 2019 at 05:23:01PM +0200, Torben Hohn wrote:
> On Wed, Aug 07, 2019 at 04:34:41PM +0200, dion at linutronix.de wrote:
> > From: Olivier Dion <dion at linutronix.de>
> >
> > Signed-off-by: Olivier Dion <dion at linutronix.de>
>
> Acked-by: Torben Hohn <torben.hohn at linutronix.de>
>
>
> not enough commit log.
> please imagine, that one might read this out of the context of this
> queue in 2 years.
>
> so ... at least an example should be here.
> anyways... then one has to dig a bit, and finds the commits with
> the proper log...
>
> > ---
> > elbepack/finetuning.py | 21 +++++++++++++++++++++
> > 1 file changed, 21 insertions(+)
> >
> > diff --git a/elbepack/finetuning.py b/elbepack/finetuning.py
> > index 7f20436e..730cfdcc 100644
> > --- a/elbepack/finetuning.py
> > +++ b/elbepack/finetuning.py
> > @@ -23,6 +23,7 @@ from elbepack.shellhelper import CommandError
> > from elbepack.filesystem import ImgMountFilesystem
> > from elbepack.packers import default_packer, packers
> > from elbepack.egpg import unlock_key
> > +from elbepack.junit import TestSuite, TestException
> >
> >
> > class FinetuningException(Exception):
> > @@ -674,6 +675,26 @@ class CopyToPartition(ImageFinetuningAction):
> > log.do(cmd)
> >
> >
> > + at FinetuningAction.register("unit-tests")
> > +class TestSuites(FinetuningAction):
> > +
> > + elbe_junit = "elbe-junit.xml"
> > +
> > + def execute_prj(self, log, buildenv, target, builddir):
> > +
> > + tss = []
> > + output = os.path.join(builddir, elbe_junit)
> > + target.images.append(elbe_junit)
oh... please append it to images, only when it has been written.
so when its not written due to an exception, its not showing up.
> > +
> > + for test_suite in self.node:
> > + ts = TestSuite(test_suite, target)
> > + try:
> > + tss.append(ts())
> > + except TestException as E:
> > + log.printo(str(E))
> > +
> > + TestSuite.to_file(output, tss)
want it here:
target.images.append(elbe_junit)
> > +
> > def do_finetuning(xml, log, buildenv, target):
> >
> > if not xml.has('target/finetuning'):
> > --
> > 2.11.0
> >
> >
> > _______________________________________________
> > elbe-devel mailing list
> > elbe-devel at linutronix.de
> > https://lists.linutronix.de/mailman/listinfo/elbe-devel
>
> --
> Torben Hohn
> Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-Mühlhofen
> Phone: +49 7556 25 999 18; Fax.: +49 7556 25 999 99
>
> Hinweise zum Datenschutz finden Sie hier (Informations on data privacy
> can be found here): https://linutronix.de/kontakt/Datenschutz.php
>
> Linutronix GmbH | Firmensitz (Registered Office): Uhldingen-Mühlhofen |
> Registergericht (Registration Court): Amtsgericht Freiburg i.Br., HRB700
> 806 | Geschäftsführer (Managing Directors): Heinz Egger, Thomas Gleixner
>
> _______________________________________________
> elbe-devel mailing list
> elbe-devel at linutronix.de
> https://lists.linutronix.de/mailman/listinfo/elbe-devel
--
Torben Hohn
Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-Mühlhofen
Phone: +49 7556 25 999 18; Fax.: +49 7556 25 999 99
Hinweise zum Datenschutz finden Sie hier (Informations on data privacy
can be found here): https://linutronix.de/kontakt/Datenschutz.php
Linutronix GmbH | Firmensitz (Registered Office): Uhldingen-Mühlhofen |
Registergericht (Registration Court): Amtsgericht Freiburg i.Br., HRB700
806 | Geschäftsführer (Managing Directors): Heinz Egger, Thomas Gleixner
More information about the elbe-devel
mailing list