summaryrefslogtreecommitdiff
path: root/ext/calendar/tests/easter_date.phpt
blob: a7cdbea51642809a821c435f62575555e02a2ec3 (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
25
--TEST--
easter_date()
--INI--
date.timezone=UTC
--ENV--
TZ=UTC
--SKIPIF--
<?php include 'skipif.inc'; ?>
--FILE--
<?php
putenv('TZ=UTC');
echo date("Y-m-d", easter_date(2000))."\n";
echo date("Y-m-d", easter_date(2001))."\n";
echo date("Y-m-d", easter_date(2002))."\n";
try {
    easter_date(1492);
} catch (ValueError $ex) {
    echo "{$ex->getMessage()}\n";
}
?>
--EXPECT--
2000-04-23
2001-04-15
2002-03-31
This function is only valid for years between 1970 and 2037 inclusive