summaryrefslogtreecommitdiff
path: root/spec/ruby/core/encoding/converter/destination_encoding_spec.rb
blob: 481a857909fd55fcf3d00c8ed21d51593f40ad1c (plain)
1
2
3
4
5
6
7
8
9
10
11
require_relative '../../../spec_helper'

describe "Encoding::Converter#destination_encoding" do
  it "returns the destination encoding as an Encoding object" do
    ec = Encoding::Converter.new('ASCII','Big5')
    ec.destination_encoding.should == Encoding::BIG5

    ec = Encoding::Converter.new('SJIS','EUC-JP')
    ec.destination_encoding.should == Encoding::EUC_JP
  end
end