pike.git / lib / modules / Calendar.pmod / testsuite.in

version» Context lines:

pike.git/lib/modules/Calendar.pmod/testsuite.in:21:   test_eval_error(Calendar.Second()->set_timezone("n"))      test_eq(Calendar.ISO_UTC.dwim_time("2000-03-26 02:01:17")->unix_time(),    954036077)      test_do(Calendar.TimeRange t = Calendar.now())      dnl Some more or less odd timezones encountered by Xenofarm:   define(test_dwim,[[    test_eq(Calendar.ISO.set_timezone("CET")->dwim_time($1)->format_time(),"2002-11-19 07:04:03") +  ifelse($2,,,[[    test_eq(Calendar.ISO.set_timezone("CET")->dwim_time($1)->tzname(),$2)    ]]) -  + ]])   test_dwim("Tue Nov 19 07:04:03 MET 2002","MET")   test_dwim("Tue Nov 19 07:04:03 CST 2002","CST")   test_dwim("Tue Nov 19 07:04:03 CET 2002","CET")   test_dwim("Tue Nov 19 07:04:03 2002","CET")   dnl NFT (Norway-France Time) is the name for CET on AIX.   test_dwim("Tue Nov 19 07:04:03 NFT 2002","CET")   test_dwim("Tue Nov 19 07:04:03 DFT 2002","CET")   test_dwim("Tue Nov 19 07:04:03 MET DST 2002","MET")   test_dwim("Tue Nov 19 07:04:03 METDST 2002","MET")   test_dwim([["Tue, 19 Nov 2002 07:04:03 GMT"]],"GMT")   test_dwim([["Tuesday, 19-Nov-02 07:04:03 GMT"]],"GMT")   test_dwim("Tue Nov 19 07:04:03 2002","GMT") -  + test_dwim("20021119T070403 GMT","GMT") + test_dwim("20021119T070403") + test_dwim("20021119 070403 GMT","GMT") + test_dwim("20021119 070403")      define(test_http,[[    test_eq(Calendar.ISO.http_time($1)->format_time(),$2)   ]])   test_http([["Tue, 19 Nov 2002 07:04:03 GMT"]],"2002-11-19 07:04:03")   test_http([["Tuesday, 19-Nov-02 07:04:03 GMT"]],"2002-11-19 07:04:03")   test_http("Tue Nov 1 07:04:03 2002","2002-11-01 07:04:03")   test_http("Tue Nov 19 07:04:03 2002","2002-11-19 07:04:03")      test_eq(arrayp(Calendar.TZnames.zonenames()), 1)