Sha256: 9d12754dcbcfd7f4c132103d4df551ebe1b134a6cb7bf5756b424e10444d695c

Contents?: true

Size: 828 Bytes

Versions: 96

Compression:

Stored size: 828 Bytes

Contents

require 'spec_helper'

describe FbGraph::Connections::Videos do
  describe '#videos' do
    it 'should return videos as FbGraph::Video' do
      mock_graph :get, 'kirk/videos', 'users/videos/kirk_private', :access_token => 'access_token' do
        videos = FbGraph::User.new('kirk', :access_token => 'access_token').videos
        videos.each do |video|
          video.should be_instance_of(FbGraph::Video)
        end
      end
    end
  end

  describe '#video!' do
    it 'should return generated photo' do
      mock_graph :post, 'me/videos', 'users/videos/posted' do
        me = FbGraph::User.me('access_token')
        video = me.video!(
          :source => Tempfile.new('movie_file')
        )
        video.should be_a FbGraph::Video
        video.identifier.should == '10150241488822277'
      end
    end
  end
end

Version data entries

96 entries across 96 versions & 1 rubygems

Version Path
fb_graph-2.4.16 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.15 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.14 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.13 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.12 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.11 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.10 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.9 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.8 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.7 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.6 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.4 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.3 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.2 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.1 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.4.0 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.3.2 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.3.1 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.3.0 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.2.6 spec/fb_graph/connections/videos_spec.rb