Sha256: c3dc1e7f8c716b6a59809a2cea50a7281ed561cde224a9b3c5ea274595c5262d
Contents?: true
Size: 1.32 KB
Versions: 1
Compression:
Stored size: 1.32 KB
Contents
require 'spec_helper' describe Mail::ContentDescriptionField do # Content-Description Header Field # # The ability to associate some descriptive information with a given # body is often desirable. For example, it may be useful to mark an # "image" body as "a picture of the Space Shuttle Endeavor." Such text # may be placed in the Content-Description header field. This header # field is always optional. # # description := "Content-Description" ":" *text # # The description is presumed to be given in the US-ASCII character # set, although the mechanism specified in RFC 2047 may be used for # non-US-ASCII Content-Description values. # describe "initialization" do it "should initialize" do doing { Mail::ContentDescriptionField.new("Content-Description: This is a description") }.should_not raise_error end it "should accept a string with the field name" do t = Mail::ContentDescriptionField.new('Content-Description: This is a description') t.name.should == 'Content-Description' t.value.should == 'This is a description' end it "should accept a string without the field name" do t = Mail::ContentDescriptionField.new('This is a description') t.name.should == 'Content-Description' t.value.should == 'This is a description' end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rack-mail_exception-0.0.1 | vendor/mail/spec/mail/fields/content_description_field_spec.rb |