spec/imagebin_spec.rb in dougsko-imagebin-0.2.3 vs spec/imagebin_spec.rb in dougsko-imagebin-0.3.0

- old
+ new

@@ -1,7 +1,24 @@ require 'spec_helper' describe "Imagebin" do - it "fails" do - fail "hey buddy, you should probably rename this file and start specing for real" - end + before do + options = { "t" => "file", + "name" => "", + "tags" => "", + "description" => "", + "adult" => "t", + "f" => "spec/ZGrass04.jpg", + } + @ibin = Imagebin.new(options) + end + + it "should return a link to the paste's website" do + link = @ibin.site_link + link.should match(/html/) + end + + it "should return a link to the picture file" do + link = @ibin.pic_link + link.should match(/jpg/) + end end