From 93c65f25eafb3051a86140ab7e980d03431040f1 Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Tue, 25 Sep 2012 09:52:28 -0700 Subject: [PATCH] Remove Twitter::API#network_timeline --- lib/twitter/api.rb | 19 ------------------- spec/twitter/api/statuses_spec.rb | 18 ------------------ 2 files changed, 37 deletions(-) diff --git a/lib/twitter/api.rb b/lib/twitter/api.rb index 8440d0f16..844b1ed97 100644 --- a/lib/twitter/api.rb +++ b/lib/twitter/api.rb @@ -1620,25 +1620,6 @@ def media_timeline(*args) objects_from_response(Twitter::Tweet, :get, "/1.1/statuses/media_timeline.json", args) end - # Returns the 20 most recent Tweets from the authenticating user's network - # - # @note Undocumented - # @rate_limited Yes - # @authentication_required Requires user context - # @raise [Twitter::Error::Unauthorized] Error raised when supplied user credentials are not valid. - # @return [Array] - # @param options [Hash] A customizable set of options. - # @option options [Integer] :since_id Returns results with an ID greater than (that is, more recent than) the specified ID. - # @option options [Integer] :max_id Returns results with an ID less than (that is, older than) or equal to the specified ID. - # @option options [Integer] :count Specifies the number of records to retrieve. Must be less than or equal to 200. - # @option options [Boolean, String, Integer] :trim_user Each tweet returned in a timeline will include a user object with only the author's numerical ID when set to true, 't' or 1. - # @option options [Boolean, String, Integer] :exclude_replies This parameter will prevent replies from appearing in the returned timeline. Using exclude_replies with the count parameter will mean you will receive up-to count tweets - this is because the count parameter retrieves that many tweets before filtering out retweets and replies. - # @example Return the 20 most recent Tweets from the authenticating user's network - # Twitter.network_timeline - def network_timeline(options={}) - collection_from_response(Twitter::Tweet, :get, "/i/statuses/network_timeline.json", options) - end - # Show up to 100 users who retweeted the Tweet # # @see https://dev.twitter.com/docs/api/1.1/get/statuses/retweets/:id diff --git a/spec/twitter/api/statuses_spec.rb b/spec/twitter/api/statuses_spec.rb index e76411a91..ab40d5119 100644 --- a/spec/twitter/api/statuses_spec.rb +++ b/spec/twitter/api/statuses_spec.rb @@ -291,24 +291,6 @@ end end - describe "#network_timeline" do - before do - stub_get("/i/statuses/network_timeline.json"). - to_return(:body => fixture("statuses.json"), :headers => {:content_type => "application/json; charset=utf-8"}) - end - it "requests the correct resource" do - @client.network_timeline - a_get("/i/statuses/network_timeline.json"). - should have_been_made - end - it "returns the 20 most recent tweets of the authenticated user that have been retweeted by others" do - tweets = @client.network_timeline - tweets.should be_an Array - tweets.first.should be_a Twitter::Tweet - tweets.first.text.should eq "Happy Birthday @imdane. Watch out for those @rally pranksters!" - end - end - describe "#retweeters_of" do context "with ids_only passed" do before do