[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cmocka adaptions for Behavior driven development

On Thursday, 29 June 2017 09:14:57 CEST Vestre, Frederik wrote:
> > On Tuesday, 13 June 2017 13:57:20 CEST Vestre, Frederik wrote:
> > > Hi
> > 
> > Hello Frederick,
> > 
> > > I have made some additions to cmocka to support BDD style testing (
> > > loosely inspired by
> > > https://github.com/philsquared/Catch/blob/master/docs/tutorial.md ).
> > > Is it possible to get these changes included into cmocka, if so how do I
> > > proceed?> 
> > this sounds like:
> > 
> > https://git.cryptomilk.org/projects/cmocka.git/tree/include/cmocka_pbc.h
> > 
> > is that the same?
> It covers some parts of it, what it does not cover is the optional sections,
> i.e. to rerun the test in all combinations skipping parts of it.
> > > I have gotten permission from my manager to release this under the
> > > Apache license in order to be compatible with the cmocka project. The
> > > changes are attached to this e-mail. I also have the changes in a
> > > local Git repository and can provide them in another format if that is
> > > preferable.> 
> > I'm open for additions but I would like to keep the main library small. So
> > it would be great to have this in an additional header (maybe even a >
> > library).
> I see, I will try to think of an architecture that splits out most of the
> logic, however I need to think a bit to find the best way to run the test
> functions multiple times without making the unittest code ugly. Maybe some
> hooks in the cmocka library are needed.
> > The documentation should be added to doxygen so that everything is in one
> > place.
> I see, I will look into that.
> > I would prefer to have git formatted patches. The smaller the commits the
> > easier it is to review and integrate patches. Patches are also > easier
> > to review an change.
> Ok, I will keep sending that then (they are attached in the tarball to the
> previous e-mail).
> > I'm not sure if cmocka forks is a good name, because of the confusion with
> > the fork() system call :-)
> I agree, I will think more if I find a better name for the concept of
> splitting execution into different branches.

maybe 'cmocka branch' is a better name :-)

> > Does that make sense?
> It does, I hope to have some updates at the end of the summer taking these
> things into account.

Make commits small, if you have just renames to function in cmocka.c send them 
earlier they can already be integrated. Also feel free to show unfinished 
code, I'm happy to comment and assist.


Andreas Schneider                   GPG-ID: CC014E3D
www.cryptomilk.org                asn@xxxxxxxxxxxxxx

Cmocka adaptions for Behavior driven development"Vestre, Frederik" <Frederik.Vestre@xxxxxxxxxxxxx>
Re: Cmocka adaptions for Behavior driven developmentAndreas Schneider <asn@xxxxxxxxxxxxxx>
RE: Cmocka adaptions for Behavior driven development"Vestre, Frederik" <Frederik.Vestre@xxxxxxxxxxxxx>