Sha256: 0243de3990e45b1a7cc03751d5c44b5e1478c417441577211424a4364a3056a5

Contents?: true

Size: 824 Bytes

Versions: 26

Compression:

Stored size: 824 Bytes

Contents

require 'spec_helper'

describe FbGraph2::Edge::Videos do
  context 'included in User' do
    let(:me) { FbGraph2::User.me('token') }

    describe '#videos' do
      it 'should return an Array of FbGraph2::Video' do
        videos = mock_graph :get, 'me/videos', 'user/videos', access_token: 'token' do
          me.videos
        end
        videos.should be_instance_of FbGraph2::Edge
        videos.should_not be_blank
        videos.each do |video|
          video.should be_instance_of FbGraph2::Video
        end
      end
    end

    describe '#video!' do
      it do
        video = mock_graph :post, 'me/videos', 'success_with_id', access_token: 'token' do
          me.video! source: File.new(__FILE__), message: 'hello'
        end
        video.should be_instance_of FbGraph2::Video
      end
    end
  end
end

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
fb_graph2-0.7.7 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.6 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.5 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.4 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.3 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.2 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.6.2 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.6.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.6.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.5.3 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.5.2 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.5.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.5.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.4.4 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.4.3 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.4.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.4.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.3.2 spec/fb_graph2/edge/videos_spec.rb