mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
MINOR Testing extended dates (very far in the past and future) in
DateTest
This commit is contained in:
parent
21f7eb19e4
commit
b52c6b4f2b
@ -112,4 +112,16 @@ class DateTest extends SapphireTest {
|
||||
$range = $date->RangeString(DBField::create_field('Date', '2000-10-20'), true);
|
||||
$this->assertEquals('10th - 20th Oct 2000', $range);
|
||||
}
|
||||
|
||||
function testExtendedDates() {
|
||||
$date = DBField::create_field('Date', '1800-10-10');
|
||||
$this->assertEquals('10 Oct 1800', $date->Format('d M Y'));
|
||||
|
||||
$date = DBField::create_field('Date', '1500-10-10');
|
||||
$this->assertEquals('10 Oct 1500', $date->Format('d M Y'));
|
||||
|
||||
$date = DBField::create_field('Date', '3000-4-3');
|
||||
$this->assertEquals('03 Apr 3000', $date->Format('d M Y'));
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user