Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

23 lines (19 sloc) 0.398 kb
begin
require 'spec'
rescue LoadError
require 'rubygems'
gem 'rspec'
require 'spec'
end
dir = File.dirname(__FILE__)
$:.unshift(File.join(dir, '/../lib/'))
require dir + '/../lib/twitter'
def stdout_for(&block)
# Inspired by http://www.ruby-forum.com/topic/58647
old_stdout = $stdout
$stdout = StringIO.new
yield
output = $stdout.string
$stdout = old_stdout
output
end
Jump to Line
Something went wrong with that request. Please try again.