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.6.5 spec/fb_graph/doc_spec.rb
fb_graph-2.6.4 spec/fb_graph/doc_spec.rb
fb_graph-2.6.3 spec/fb_graph/doc_spec.rb
fb_graph-2.6.2 spec/fb_graph/doc_spec.rb
fb_graph-2.6.1 spec/fb_graph/doc_spec.rb
fb_graph-2.6.0 spec/fb_graph/doc_spec.rb
fb_graph-2.5.9 spec/fb_graph/doc_spec.rb
fb_graph-2.5.8 spec/fb_graph/doc_spec.rb
fb_graph-2.5.7 spec/fb_graph/doc_spec.rb
fb_graph-2.5.6 spec/fb_graph/doc_spec.rb
fb_graph-2.5.5 spec/fb_graph/doc_spec.rb
fb_graph-2.5.4 spec/fb_graph/doc_spec.rb
fb_graph-2.5.3 spec/fb_graph/doc_spec.rb
fb_graph-2.5.2 spec/fb_graph/doc_spec.rb
fb_graph-2.5.1 spec/fb_graph/doc_spec.rb
fb_graph-2.5.0 spec/fb_graph/doc_spec.rb
fb_graph-2.4.20 spec/fb_graph/doc_spec.rb
fb_graph-2.4.19 spec/fb_graph/doc_spec.rb
fb_graph-2.4.18 spec/fb_graph/doc_spec.rb
fb_graph-2.4.17 spec/fb_graph/doc_spec.rb