require File.expand_path('../../spec_helper', __FILE__) describe Yammer::Api::Topic do before :all do @client = Yammer::Client.new( :site_url => 'https://www.yammer.com', :client_id => 'PRbTcg9qjgKsp4jjpm1pw', :client_secret => 'Xn7kp7Ly0TCY4GtZWkmSsqGEPg10DmMADyjWkf2U', :access_token => 'TolNOFka9Uls2DxahNi78A' ) end subject { @client } describe '#topics' do it 'should fetch topic' do subject.should_receive(:get).with('/api/v1/topics/1',{ :is_followed_by => 2 }) subject.get_topic(1, :is_followed_by => 2) end end end