r22464 - gnucash/trunk/src/backend/dbi/test - Enable and correct all store-and-reload basic tests

John Ralls jralls at ceridwen.us
Tue Oct 30 20:42:12 EDT 2012


On Oct 30, 2012, at 1:58 PM, Geert Janssens <janssens-geert at telenet.be> wrote:

> On 30-10-12 20:24, Alex Aycinena wrote:
>> John,
>> 
>> On Sun, Oct 28, 2012 at 5:43 PM, John Ralls <jralls at ceridwen.us> wrote:
>>> And what is "check-local"?
>> "check-local" is not what I entered but what was played back on my
>> terminal from 'make check'; see it below in your own output after the
>> line for changing directory to
>> `/home/john/gnucash/src/backend/dbi/test':
>> 
>>> john at Wheezy:~/gnucash$ cd src/backend/dbi
>>> john at Wheezy:~/gnucash/src/backend/dbi$ make check-local
>>> make: *** No rule to make target `check-local'.  Stop.
>>> 
>>> But for make check:
>>> john at Wheezy:~/gnucash/src/backend/dbi$ make check
>>> Making check in .
>>> make[1]: Entering directory `/home/john/gnucash/src/backend/dbi'
>>> make[1]: Nothing to be done for `check-am'.
>>> make[1]: Leaving directory `/home/john/gnucash/src/backend/dbi'
>>> Making check in test
>>> make[1]: Entering directory `/home/john/gnucash/src/backend/dbi/test'
>>> make  check-local
>>> make[2]: Entering directory `/home/john/gnucash/src/backend/dbi/test'
>>> TEST: test-backend-dbi... (pid=15469)
>>>  /backend/dbi/store_and_reload/sqlite:                                OK
>>>  /backend/dbi/store_and_reload/mysql:                                 OK
>>>  /backend/dbi/store_and_reload/postgres:                              OK
>>>  /backend/dbi/gnc dbi test sqlite (business):                         OK
>>> PASS: test-backend-dbi
>>> make[2]: Leaving directory `/home/john/gnucash/src/backend/dbi/test'
>>> make[1]: Leaving directory `/home/john/gnucash/src/backend/dbi/test'
>>> john at Wheezy:~/gnucash/src/backend/dbi$
>>> 
>>> 
>>> What version of glib do you have?
>> I'm on Fedora 15: glib is 2-2.28.8
>> 
>>> Regards,
>>> John Ralls
>>> 
>> I'm on trunk at revision 22473. I use a different build directory from
>> the source. When I 'make' it builds fine but:
>> 
>> [gnucash-dev at HPdv5Fedora gnucash-clean-build]$ cd src/backend/dbi
>> [gnucash-dev at HPdv5Fedora dbi]$ make check
>> Making check in .
>> make[1]: Entering directory
>> `/home/gnucash-dev/svncheckouts/gnucash-clean-build/src/backend/dbi'
>> make[1]: Nothing to be done for `check-am'.
>> make[1]: Leaving directory
>> `/home/gnucash-dev/svncheckouts/gnucash-clean-build/src/backend/dbi'
>> Making check in test
>> make[1]: Entering directory
>> `/home/gnucash-dev/svncheckouts/gnucash-clean-build/src/backend/dbi/test'
>> make  check-local
>> make[2]: Entering directory
>> `/home/gnucash-dev/svncheckouts/gnucash-clean-build/src/backend/dbi/test'
>> TEST: test-backend-dbi... (pid=19279)
>>  /backend/dbi/store_and_reload/sqlite:                                FAIL
>> GTester: last random seed: R02Sa7cac1ca5d4e400c39daba9fbb1c29e2
>> /bin/sh: line 1: 19278 Terminated              gtester --verbose
>> test-backend-dbi
>> make[2]: *** [test] Error 143
>> make[2]: Leaving directory
>> `/home/gnucash-dev/svncheckouts/gnucash-clean-build/src/backend/dbi/test'
>> make[1]: *** [check-am] Error 2
>> make[1]: Leaving directory
>> `/home/gnucash-dev/svncheckouts/gnucash-clean-build/src/backend/dbi/test'
>> make: *** [check-recursive] Error 1
>> [gnucash-dev at HPdv5Fedora dbi]$
>> 
>> So in order to make sure there wasn't something bad in my build tree,
>> I made new 'gnucash-clean' and 'gnucash-clean-build' directories,
>> checked-out a fresh set of sources and rebuilt it. "make" worked, but
>> I got the same result with "make check". Does 'Error 143' mean
>> anything to you?
> 
> I'm also building out of tree. I remember I had to make a softlink to the xml test file from the source directory to the build directory before the tests worked. This may have to be corrected in the build scripts.

Ah, that's the likely culprit. There's an XML file that's loaded by the XML backend, and the test will program will crash if it can't find the file. Before my last round of changes the test program didn't even try to load because the xml backend wasn't loaded. There weren't any asserts to check that it had, so it would always pass without actually testing anything. Odd, though, that you're getting that weird error message instead of the assert message from checking for backend errors right after trying to load the file.

Regards,
John Ralls


More information about the gnucash-devel mailing list