Sha256: 1e3c694a8fa8ea25e957bc7388b20ce1e50a76b680e75cd7760ab75ce55efe82
Contents?: true
Size: 887 Bytes
Versions: 11
Compression:
Stored size: 887 Bytes
Contents
require 'spec_helper' describe Net::NTLM::FieldSet do fields = [] it_behaves_like 'a fieldset', fields subject(:fieldset_class) do Class.new(Net::NTLM::FieldSet) end context 'an instance' do subject(:fieldset_object) do fieldset_class.string(:test_string, { :value => 'Test', :active => true, :size => 4}) fieldset_class.string(:test_string2, { :value => 'Foo', :active => true, :size => 3}) fieldset_class.new end it 'should serialize all the fields' do expect(fieldset_object.serialize).to eq('TestFoo') end it 'should parse a string across the fields' do fieldset_object.parse('FooBarBaz') expect(fieldset_object.serialize).to eq('FooBarB') end it 'should return an aggregate size of all the fields' do expect(fieldset_object.size).to eq(7) end end end
Version data entries
11 entries across 11 versions & 3 rubygems