Sha256: b7d0c7ad5f0c5ba49184c50029c600f99c87ad4eb73e19fe68335025bede5d6e
Contents?: true
Size: 727 Bytes
Versions: 11
Compression:
Stored size: 727 Bytes
Contents
require 'spec_helper' describe CF::Data do subject {CF::Data.from_string('A CF string')} describe '#to_s' do it 'should return a binary ruby string' do ruby_string = subject.to_s ruby_string.should == 'A CF string' if CF::String::HAS_ENCODING ruby_string.encoding.should == Encoding::ASCII_8BIT end end end describe '#size' do it 'should return the size in bytes of the cfdata' do subject.size.should == 11 end end describe 'to_ruby' do it 'should behave like to_s' do subject.to_ruby.should == 'A CF string' if 'A CF string'.respond_to? "encoding" subject.to_ruby.encoding.should == Encoding::ASCII_8BIT end end end end
Version data entries
11 entries across 8 versions & 3 rubygems