explicitly set timezone for tests that depend on it
authorPhilipp Gesang <philipp.gesang@intra2net.com>
Thu, 25 Apr 2019 14:20:36 +0000 (16:20 +0200)
committerPhilipp Gesang <philipp.gesang@intra2net.com>
Thu, 25 Apr 2019 14:24:55 +0000 (16:24 +0200)
commit8dce1f311ab575b549495ff29a296f0c2b068386
tree1593f89f0645ab0d09726357d8436fe9499638a5
parentc3df2bda5837805d87bc2f8d6ff7c8bca8e1d6ff
explicitly set timezone for tests that depend on it

Some timefunc tests rely on the time zone to be CE[S]T and will
fail otherwise. Not a good thing for a correctness test to do, so
set the zone explicitly in those cases. Example:

    $ ./test/test_i2ncommon --run_test=TestTimeFunc/FormatFullTime
    Running 1 test case...

    *** No errors detected
    $ TZ=UTC ./test/test_i2ncommon --run_test=TestTimeFunc/FormatFullTime
    Running 1 test case...
    /home/philipp/src/i2ncommon/libi2ncommon-git/test/test_timefunc.cpp(480): error: in "TestTimeFunc/FormatFullTime": check "17.10.2011 11:33" == format_full_time(seconds) has failed [17.10.2011 11:33 != 17.10.2011 09:33]
test/test_timefunc.cpp