Sha256: 035e57a1c4caaaf5da71c436841d3668d1d1c17a68b965991033fb27db2534d5
Contents?: true
Size: 627 Bytes
Versions: 18
Compression:
Stored size: 627 Bytes
Contents
require 'spec_helper' require 'ronin/author' describe Author do it "should have a String representation" do author = Author.new(:name => 'test') author.to_s.should == 'test' end describe "#to_s" do it "should return the name when their is no email" do author = Author.new(:name => 'anonymous') author.to_s.should == 'anonymous' end it "should return the name and email when both are present" do author = Author.new( :name => 'anonymous', :email => 'anonymous@example.com' ) author.to_s.should == 'anonymous <anonymous@example.com>' end end end
Version data entries
18 entries across 18 versions & 1 rubygems