summaryrefslogtreecommitdiff
path: root/ext/date/tests/timezone_location_get.phpt
blob: 93f7ed6d75b0eb14e0470d95c4c6e5a456fc7665 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
--TEST--
timezone_location_get: Test that timezone_location_get returns a correct array of information
--CREDITS--
Havard Eide <nucleuz@gmail.com>
#PHPTestFest2009 Norway 2009-06-09 \o/
--INI--
date.timezone=UTC
--FILE--
<?php
$location = timezone_location_get(new DateTimeZone("Europe/Oslo"));
var_dump($location);
?>
--EXPECTF--
array(4) {
  ["country_code"]=>
  string(2) "NO"
  ["latitude"]=>
  float(59.9166%d)
  ["longitude"]=>
  float(10.75)
  ["comments"]=>
  string(0) ""
}