GNOME Bugzilla – Bug 772662
Test failures on current maint branch
Last modified: 2018-06-29 23:51:29 UTC
While testing fixes for the sometimes failing test-report-utilities, I have been running lots of "make check" commands with different timezones set (by exporting the TZ environment variable). I run into a number of test failures in the qof test suite when using timezones of TZ=GMT+11 or TZ=GMT+12 (is that supposed to be a valid timezone like for New Zealand with DST ?). Each of them fails at a different point. Here's the summary: 1. With TZ=GMT+11 Failing test: test_gnc_print_date This error is printed in between the test results: ERROR:/kobaltnet/janssege/Development/gnucash/gnucash/src/libqof/qof/test/test-gnc-date.c:1338:test_gnc_print_date: assertion failed (gnc_print_date (tm1) == "23/11/1974"): ("22/11/1974" == "23/11/1974") 2. With TZ=GMT+12 Failing test: test_gnc_dmy2timespec_neutral This error is printed in between the test results: ERROR:/kobaltnet/janssege/Development/gnucash/gnucash/src/libqof/qof/test/test-gnc-date.c:1987:test_gnc_dmy2timespec_neutral: assertion failed (r_t.tv_sec == t.tv_sec): (932561940 == 932554740)
NZST is GMT+12, NZDT is GMT+13. That's why the base time needs to be 10:59, so that 10:59 + 13 = 23:59, still the same day. Interesting. I built with cmake + ninja and got clean tests on all TZs, albeit with OS X rather than Linux. While I think I'll leave this until I can test more thoroughly, I'd like to know if you get different test results with cmake & ninja from autotools.
I'll try that build tomorrow
Hmm, what's the procedure to build with ninja ? I have run cmake which gives me makefiles to work with, so I'm still using make && make check. I suppose ninja needs something else? The cmake - makefiles combination still breaks for TZ=GMT+11
Ok, false alert. TZ=abc+11 actually means we're testing for timezone UTC-11. That's the one timezoe we are not guaranteeing consistent date behaviour to be able to correctly support DST in New Zealand (UTC+13). So all works as expected.
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=772662. Please update any external references or bookmarks.