diff options
Diffstat (limited to 'spec/ruby/core/time')
-rw-r--r-- | spec/ruby/core/time/_load_spec.rb | 12 | ||||
-rw-r--r-- | spec/ruby/core/time/shared/inspect.rb | 6 |
2 files changed, 7 insertions, 11 deletions
diff --git a/spec/ruby/core/time/_load_spec.rb b/spec/ruby/core/time/_load_spec.rb index 5f6275d46c..152934370f 100644 --- a/spec/ruby/core/time/_load_spec.rb +++ b/spec/ruby/core/time/_load_spec.rb @@ -43,12 +43,10 @@ describe "Time._load" do t.to_s.should == "2010-10-22 16:57:48 UTC" end - with_feature :encoding do - it "treats the data as binary data" do - data = "\x04\bu:\tTime\r\fM\x1C\xC0\x00\x00\xD0\xBE" - data.force_encoding Encoding::UTF_8 - t = Marshal.load(data) - t.to_s.should == "2013-04-08 12:47:45 UTC" - end + it "treats the data as binary data" do + data = "\x04\bu:\tTime\r\fM\x1C\xC0\x00\x00\xD0\xBE" + data.force_encoding Encoding::UTF_8 + t = Marshal.load(data) + t.to_s.should == "2013-04-08 12:47:45 UTC" end end diff --git a/spec/ruby/core/time/shared/inspect.rb b/spec/ruby/core/time/shared/inspect.rb index c707382a6e..4133671924 100644 --- a/spec/ruby/core/time/shared/inspect.rb +++ b/spec/ruby/core/time/shared/inspect.rb @@ -15,9 +15,7 @@ describe :inspect, shared: true do Time.new(2000, 1, 1, 20, 15, 01, 3600).send(@method).should == "2000-01-01 20:15:01 +0100" end - with_feature :encoding do - it "returns a US-ASCII encoded string" do - Time.now.send(@method).encoding.should equal(Encoding::US_ASCII) - end + it "returns a US-ASCII encoded string" do + Time.now.send(@method).encoding.should equal(Encoding::US_ASCII) end end |