Sha256: 5aee4b679bfdab4f2bc3906b927f45b0e20e604cc7bf415f70eae1ce6ce15452
Contents?: true
Size: 781 Bytes
Versions: 1
Compression:
Stored size: 781 Bytes
Contents
require 'helper' describe Pinboard::Client do describe "#posts" do let(:client) { Pinboard::Client.new(auth_params) } before do stub_get("posts/all?"). to_return(:body => fixture("posts_all.xml"), :headers => { 'content-type' => 'text/xml' }) end it "returns a collection of posts" do expected = [ Pinboard::Post.new( :href => "http://foo.com/", :description => "Foo!", :tag => 'foo bar', :time => Time.parse("2011-07-26T17:52:04Z")), Pinboard::Post.new( :href => "http://bar.com/", :description => "Bar!", :tag => 'foo bar', :time => Time.parse("2011-07-26T17:52:04Z")) ] client.posts.should == expected end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pinboard-0.0.3 | spec/pinboard/client_spec.rb |