Sha256: bcf71be2bf00daa081006fa7f54ec8ab51a411540154c91b208aaa7e04f507d2

Contents?: true

Size: 884 Bytes

Versions: 11

Compression:

Stored size: 884 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 'skip until webmock support multipart'
      # 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

11 entries across 11 versions & 1 rubygems

Version Path
fb_graph2-1.3.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-1.2.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-1.1.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-1.1.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-1.0.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-1.0.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.9.1 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.9.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.8.0 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.9 spec/fb_graph2/edge/videos_spec.rb
fb_graph2-0.7.8 spec/fb_graph2/edge/videos_spec.rb