Re: [Tails-dev] automated tests

Borrar esta mensaxe

Responder a esta mensaxe
Autor: intrigeri
Data:  
Para: The Tails public development discussion list
Asunto: Re: [Tails-dev] automated tests
hi,

bertagaz@??? wrote (21 Jun 2012 13:21:54 GMT) :
>> Note: given we most probably want to run the tests that were in the
>> Git repository at the very commit the ISO image was built from, either
>> the source tree must be shared between the build system and the
>> testing one, or information about the commit that was used to run the
>> build must be passed from the former to the latter.


> I might not have a sufficiently clear big pictures of all this setup. :)


> On the automated build system at least, this commits will usually be the
> last HEAD of a branch, aren't they?


Yes.

> It will probably also be the case if they are run on the developper
> system while working on a feature. Sure HEAD is a commit, but
> well... :)


I don't understand how this affects what I stated in this note.

HEAD's value changes over time. We have no guarantee that HEAD is the
same, when the testing system is handled a just-built ISO, as it was
when the build system started building this ISO.

Therefore, either the source tree must be shared (so that we can
freeze it, and have a guarantee the HEAD value has not changed) or the
commit ID must be passed. If you have an alternative solution, I'm
happy to hear about it :)

BTW, sharing the source tree introduces strong synchronous ties
between building and testing, which I don't like much. So, I tend to
prefer the message passing way (given the commit ID can be extracted
from the ISO itself, perhaps we don't even have to pass anything in
addition to the ISO -- except for optimization's sake).

> In the long run, we might want to keep the tests maintained in the same
> git workflow than the rest of the code: each $feature tests are pushed in
> the $feature/feature branch along with the concerned code, and get merged
> with this branch, say in the "stable" branch in case of a release for
> example, with the rest of the feature code.


I do agree.

> Given new features in Tails are usually developed in a "feature/foo"
> branch, we can also use cucumber's tags and tag tests according to the
> feature branch name they are related to.


>From my (ignorant) standpoint, I slightly prefer the per-feature

directory approach, and keep tags to implement other dimensions of
sorting, but I don't care much.

> This way we'll be able to start only the dedicated tests quite
> programmatically. Cause we might not want to run all the test suite
> everytime someone work on a feature (either on the build machine, or on
> the developper system), but still from time to time check it doesn't break
> the global test suite.


Agreed.

> We could also use a tag "release".


What for?

cheers,
--
intrigeri
| GnuPG key @ https://gaffer.ptitcanardnoir.org/intrigeri/intrigeri.asc
| OTR fingerprint @ https://gaffer.ptitcanardnoir.org/intrigeri/otr.asc