This patch is for ruby 1.9 compatibility but I've broken it out of the main ticket #1689 due to a change in current behavior.
Ruby 1.9 defines DateTime#xmlschema which instead of returning dates of the form 1980-02-28T15:15:10Z if the offset is 0, returns 1980-02-28T15:15:10+00:00. I propose using +00:00 so that we can rely on Ruby 1.9's native DateTime#xmlschema. Tests showing the change in format in the patch.
Other than that, the rest are 1.9 compat fixes:
- remove_method DateTime#to_time if Ruby 1.9 since it relies internally on Time. We use the currently defined #to_time in core_ext which allows DateTimes outside the range of what can be created with Time (32-bit platform limit).
- remove_method Date#xmlschema if Ruby 1.9 since it doesn't have the Time component. This is needed for XMLSchema as far as I can tell.