PHP  
 PHP_5_6
downloads | QA | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
 

Test Failure Report for ext/intl/tests/dateformat_formatObject_datetime.phpt ('IntlDateFormatter::formatObject(): DateTime tests')

Script

1: <?php
2: ini_set
("intl.error_level"E_WARNING);
3:
ini_set("intl.default_locale""pt_PT");
4:
ini_set("date.timezone""Europe/Lisbon");
5:
6:
$dt = new DateTime('2012-01-01 00:00:00'); //Europe/Lisbon
7:
echo IntlDateFormatter::formatObject($dt), "\n";
8: echo 
IntlDateFormatter::formatObject($dtIntlDateFormatter::FULL), "\n";
9: echo 
IntlDateFormatter::formatObject($dtnull"en-US"), "\n";
10: echo 
IntlDateFormatter::formatObject($dt, array(IntlDateFormatter::SHORTIntlDateFormatter::FULL), "en-US"), "\n";
11: echo 
IntlDateFormatter::formatObject($dt'E y-MM-d HH,mm,ss.SSS v'"en-US"), "\n";
12:
13:
$dt = new DateTime('2012-01-01 05:00:00+03:00');
14: echo 
IntlDateFormatter::formatObject($dtIntlDateFormatter::FULL), "\n";
15:
16:
?>
17:
==DONE==
18:
19:

Expected

01/01/2012 00:00:00
Domingo, 1 de Janeiro de 2012 0:00:00 Hora %Sda Europa Ocidental
Jan 1, 2012 12:00:00 AM
1/1/12 12:00:00 AM Western European %STime
Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon)
Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00
==DONE==

Output

1 de Jan de 2012 00:00:00
domingo, 1 de Janeiro de 2012 00h00min00s Hora da Europa Ocidental
Jan 1, 2012 12:00:00 AM
1/1/12 12:00:00 AM Western European Time
Sun 2012-01-1 00,00,00.000 Portugal (Lisbon)
domingo, 1 de Janeiro de 2012 05h00min00s GMT+03:00
==DONE==

Diff

001+ 1 de Jan de 2012 00:00:00
002+ domingo, 1 de Janeiro de 2012 00h00min00s Hora da Europa Ocidental
001- 01/01/2012 00:00:00
002- Domingo, 1 de Janeiro de 2012 0:00:00 Hora %Sda Europa Ocidental
005+ Sun 2012-01-1 00,00,00.000 Portugal (Lisbon)
006+ domingo, 1 de Janeiro de 2012 05h00min00s GMT+03:00
005- Sun 2012-01-1 00,00,00.000 Portugal Time (Lisbon)
006- Domingo, 1 de Janeiro de 2012 5:00:00 GMT+03:00

 

Generated at Tue, 28 Oct 2014 09:43:43 +0000 (3 days ago)

Copyright © 2005-2014 The PHP Group
All rights reserved.