Sha256: e6bb209e6a45385ce2626b2d22f05a29aca6295cbb7dcfc5f381c76b0c50c2b9
Contents?: true
Size: 646 Bytes
Versions: 36
Compression:
Stored size: 646 Bytes
Contents
require File.dirname(__FILE__) + '/test_helper' require 'mofo/hreview' alias :real_open :open def open(input) input[/^http/] ? open(fixture(:corkd)) : real_open(input) end context "Grabbing an hReview from a URL" do setup do url = 'http://www.corkd.com/views/123' $url_hreview ||= HReview.find(:first => url) end specify "should add the base URL to all nested relative links" do $url_hreview.reviewer.url.should.equal 'http://www.corkd.com/people/simplebits' end specify "should not add the base URL to absolute links" do $url_hreview.reviewer.photo.should.equal 'http://flickr.com/img/icon-user-64.gif' end end
Version data entries
36 entries across 23 versions & 3 rubygems