Master gtest-gnc-datetime test fails.
John Ralls
jralls at ceridwen.us
Sat Apr 15 10:15:00 EDT 2017
> On Apr 15, 2017, at 4:27 AM, Robert Fewell <14ubobit at gmail.com> wrote:
>
> Hi,
>
> Built current master on my Linux VM and tried to run the tests but it fails
> on the following test, if they are commented out all other tests run
> successfully.
>
> Checked my time zone information to be Europe/London
>
> I think the offset is the difference between local time and utc time, so
> the first two failures are comparing times in GMT to UTC which I think are
> the same so expect 0 and the last one is after we have switched to BST and
> so 3600 makes sense to me.
>
> zdump /etc/localtime
> /etc/localtime Sat Apr 15 12:14:57 2017 BST
>
>
> gtest-gnc-datetime.cpp:103: Failure
> Value of: gncdt1.offset()
> Actual: 0
> Expected: -28800
> gtest-gnc-datetime.cpp:105: Failure
> Value of: gncdt2.offset()
> Actual: 0
> Expected: -25200
> gtest-gnc-datetime.cpp:107: Failure
> Value of: gncdt3.offset()
> Actual: 3600
> Expected: -25200
>
> Not sure how to fix apart from changing the expected values.
>
The tests are checking that the offset is calculated correctly and works only in Pacific Time (UTC - 8:00). If you run
TZ=America/LosAngeles make check
it will pass.
Regards,
John Ralls
More information about the gnucash-devel
mailing list