guzzle/guzzle — pull request #308 by jeremeamia (2013-04-29 20:31:44+00:00)
Title: Fixed two issues with the date formatting logic in SchemaFormatter

This PR fixes two issues with the date formatting logic in `Guzzle\Service\Description\SchemaFormatter`.

1. Integer timestamps, if passed in as a string, previously caused an exception to be thrown like this: `Exception: DateTime::__construct(): Failed to parse time string`... I moved the `is_numeric()` condition to the top of `SchemaFormatter::dateFormatter` in order to handle this appropriately.
2. Date strings formatted with the timezone included previously caused unexpected results. The date outputted by the `SchemaFormatter` would be in UTC format, but still have the hour value from the originally specified timezone. This was happening because the timezone parameter in the constructor for `DateTime` is ignored when the timezone is specified in the time argument. I changed the `SchemaFormatter::dateFormatter` method to use the `setTimezone()` method instead.

I also added test cases to make use these types of values are exercised by the unit test.