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.7.17 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.16 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.15 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.14 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.13 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.12 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.11 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.10 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.9 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.8 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.7 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.6 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.5 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.4 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.3 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.2 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.1 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.7.0 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.6.7 spec/fb_graph/connections/videos_spec.rb
fb_graph-2.6.6 spec/fb_graph/connections/videos_spec.rb