r21525 - gnucash/trunk/src - [Engine Unit Testing] Unit tests for Account.c

Christian Stimming christian at cstimming.de
Sun Nov 6 16:02:24 EST 2011


Am Sonntag, 6. November 2011 schrieb John Ralls:
> Author: jralls
> Date: 2011-11-05 19:05:00 -0400 (Sat, 05 Nov 2011)
> New Revision: 21525
> Trac: http://svn.gnucash.org/trac/changeset/21525
> 
> Added:
>    gnucash/trunk/src/engine/test/test-engine.c
>    gnucash/trunk/src/engine/test/utest-Account.c
> Modified:
>    gnucash/trunk/src/engine/Account.c
>    gnucash/trunk/src/engine/Account.h
>    gnucash/trunk/src/engine/AccountP.h
>    gnucash/trunk/src/engine/test/Makefile.am
>    gnucash/trunk/src/libqof/qof/test/Makefile.am
> Log:
> [Engine Unit Testing] Unit tests for Account.c

Thanks for starting with the large task of adding unit tests in this area!

Unfortunately, this commit contains a few compile errors:

gnc_coll_get_root_account() needs to be declared static or alternatively need 
a declaration beforehand.

g_list_free_full() in utest-Account.c:455 - The function g_list_free_full() is 
new in glib-2.28 and hence not available e.g. in my glib-2.24 on a half-year 
old Ubuntu.

src/engine/test/utest-Account.c: In function 
‘test_gnc_account_list_name_violations’:
src/engine/test/utest-Account.c:440: error: ‘msg’ is used uninitialized in 
this function

I'm not completely sure how those three errors should be fixed, so I better 
leave this up to you.

Best Regards,

Christian



More information about the gnucash-devel mailing list