diff options
Diffstat (limited to 'tests/lib/DateTimeFormatterTest.php')
-rw-r--r-- | tests/lib/DateTimeFormatterTest.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/lib/DateTimeFormatterTest.php b/tests/lib/DateTimeFormatterTest.php index f7f6f6633cd..6cd8b572fcd 100644 --- a/tests/lib/DateTimeFormatterTest.php +++ b/tests/lib/DateTimeFormatterTest.php @@ -175,10 +175,10 @@ class DateTimeFormatterTest extends TestCase { $this->assertEquals($expected, (string) $this->formatter->formatDateTime($timestamp, 'long', 'long', $timeZone)); } - /** - * @expectedException \Exception - */ + function testFormatDateWithInvalidTZ() { + $this->expectException(\Exception::class); + $this->formatter->formatDate(1350129205, 'long', new \DateTimeZone('Mordor/Barad-dûr')); } } |