diff options
Diffstat (limited to 'spec/ruby/optional/capi/encoding_spec.rb')
-rw-r--r-- | spec/ruby/optional/capi/encoding_spec.rb | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/spec/ruby/optional/capi/encoding_spec.rb b/spec/ruby/optional/capi/encoding_spec.rb index ba31c84f1c..cd3f00d478 100644 --- a/spec/ruby/optional/capi/encoding_spec.rb +++ b/spec/ruby/optional/capi/encoding_spec.rb @@ -12,24 +12,6 @@ describe :rb_enc_get_index, shared: true do it "returns the index of the encoding of a Regexp" do @s.send(@method, /regexp/).should >= 0 end - - it "returns the index of the encoding of an Object" do - obj = mock("rb_enc_get_index string") - @s.rb_enc_set_index(obj, 1) - @s.send(@method, obj).should == 1 - end - - it "returns the index of the dummy encoding of an Object" do - obj = mock("rb_enc_get_index string") - index = Encoding.list.index(Encoding::UTF_16) - @s.rb_enc_set_index(obj, index) - @s.send(@method, obj).should == index - end - - it "returns 0 for an object without an encoding" do - obj = mock("rb_enc_get_index string") - @s.send(@method, obj).should == 0 - end end describe :rb_enc_set_index, shared: true do @@ -48,12 +30,6 @@ describe :rb_enc_set_index, shared: true do result = @s.send(@method, str, 1) result.first.should == result.last end - - it "associates an encoding with an object" do - obj = mock("rb_enc_set_index string") - result = @s.send(@method, obj, 1) - result.first.should == result.last - end end describe "C-API Encoding function" do |