Sha256: 744f6c191908146775b26a2a33b2b44525c2ddf9c6a88e15878601521c53a16b

Contents?: true

Size: 852 Bytes

Versions: 95

Compression:

Stored size: 852 Bytes

Contents

require 'spec_helper'

describe FbGraph::Doc do
  describe '.new' do
    let :attributes do
      {
        :id => '12345',
        :from => {
          :id => '123456',
          :name => 'Nov Matake'
        },
        :subject => 'Subject',
        :icon => 'https://s-static.ak.facebook.com/rsrc.php/v1/yi/r/-64q65AWgXb.png',
        :updated_time => '2011-03-12T02:43:04+0000',
        :revision => 207279219287628
      }
    end
    it 'should setup all supported attributes' do
      doc = FbGraph::Doc.new(attributes[:id], attributes)
      doc.identifier.should == '12345'
      doc.from.should == FbGraph::User.new('123456', :name => 'Nov Matake')
      doc.subject.should == 'Subject'
      doc.icon.should == 'https://s-static.ak.facebook.com/rsrc.php/v1/yi/r/-64q65AWgXb.png'
      doc.revision.should == 207279219287628
    end
  end
end

Version data entries

95 entries across 95 versions & 1 rubygems

Version Path
fb_graph-2.7.17 spec/fb_graph/doc_spec.rb
fb_graph-2.7.16 spec/fb_graph/doc_spec.rb
fb_graph-2.7.15 spec/fb_graph/doc_spec.rb
fb_graph-2.7.14 spec/fb_graph/doc_spec.rb
fb_graph-2.7.13 spec/fb_graph/doc_spec.rb
fb_graph-2.7.12 spec/fb_graph/doc_spec.rb
fb_graph-2.7.11 spec/fb_graph/doc_spec.rb
fb_graph-2.7.10 spec/fb_graph/doc_spec.rb
fb_graph-2.7.9 spec/fb_graph/doc_spec.rb
fb_graph-2.7.8 spec/fb_graph/doc_spec.rb
fb_graph-2.7.7 spec/fb_graph/doc_spec.rb
fb_graph-2.7.6 spec/fb_graph/doc_spec.rb
fb_graph-2.7.5 spec/fb_graph/doc_spec.rb
fb_graph-2.7.4 spec/fb_graph/doc_spec.rb
fb_graph-2.7.3 spec/fb_graph/doc_spec.rb
fb_graph-2.7.2 spec/fb_graph/doc_spec.rb
fb_graph-2.7.1 spec/fb_graph/doc_spec.rb
fb_graph-2.7.0 spec/fb_graph/doc_spec.rb
fb_graph-2.6.7 spec/fb_graph/doc_spec.rb
fb_graph-2.6.6 spec/fb_graph/doc_spec.rb