test/cases/dsl-local-date-time-functions/strptime-z/mlr
raw| 1 | end { |
| 2 | tzs = ["UTC", "America/Sao_Paulo", "Asia/Istanbul"]; |
| 3 | |
| 4 | for (tz in tzs) { |
| 5 | ENV["TZ"] = tz; |
| 6 | # Expect these to not vary with $TZ since we are using %z |
| 7 | intime = "1970-01-01T00:00:00-0400"; |
| 8 | parsed = strptime(intime, "%Y-%m-%dT%H:%M:%S%z"); |
| 9 | formatted = strftime(parsed, "%Y-%m-%dT%H:%M:%S%z"); |
| 10 | |
| 11 | print; |
| 12 | print "TZ ", tz; |
| 13 | print "intime ", intime; |
| 14 | print "parsed ", parsed; |
| 15 | print "formatted", formatted; |
| 16 | } |
| 17 | } |