Sha256: ed8893bd84d65e4bd4f3750857458b0effe3c6a17a0a37f3e11758d0e7e183b6
Contents?: true
Size: 459 Bytes
Versions: 1
Compression:
Stored size: 459 Bytes
Contents
require File.dirname(__FILE__) + '/../../spec_helper' require 'json' describe Time, "#to_json" do before do @expected = "\"2008-03-28T22:54:20Z\"" end it "should transform itself into a ISO 8601 compatible string" do Time.utc(2008, 3, 28, 22, 54, 20).to_json.should == @expected Time.xmlschema("2008-03-28T22:54:20Z").to_json.should == @expected Time.xmlschema("2008-03-28T17:54:20-05:00").to_json.should == @expected end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
merb-core-0.9.3 | spec/private/core_ext/time_spec.rb |