php-src/ext/intl/tests/timezone_getOffset_basic.phpt
Gina Peter Banyard c42e6d62d8
ext/intl: modernize tests (#19392)
This is effectively removing ZPP tests, enabling warnings, and moving INI settings into the INI PHPT block
2025-08-06 23:33:48 +01:00

28 lines
564 B
PHP

--TEST--
IntlTimeZone::getOffset(): basic test
--INI--
date.timezone=Atlantic/Azores
--EXTENSIONS--
intl
--FILE--
<?php
$ams = IntlTimeZone::createTimeZone('Europe/Amsterdam');
$date = strtotime("1 July 2012 +0000");
var_dump($ams->getOffset($date *1000., true, $rawOffset, $dstOffset),
$rawOffset, $dstOffset);
$lsb = IntlTimeZone::createTimeZone('Europe/Lisbon');
var_dump(intltz_get_offset($lsb, $date *1000., true, $rawOffset, $dstOffset),
$rawOffset, $dstOffset);
?>
--EXPECT--
bool(true)
int(3600000)
int(3600000)
bool(true)
int(0)
int(3600000)