mikel/mail — Issue #305: Just cannot get the tests pass, 
Author: chrism2671
Created: 2011-11-29 12:31:21+00:00
State: open

This is ruby 1.9.2p290 (darwin). I'm trying to sort an error where I get

NoMethodError (undefined method `encoding' for #)

when I'm trying to send attachments. My tests didn't get as far as encoding tests, see below. I tried this on several versions of Ruby (including p0). I'm not sure where I'm going wrong, can somebody help me get this to pass?

Pending:
Mail::AddressList parsing should handle malformed folding whitespace
# No reason given
# ./spec/mail/elements/address_list_spec.rb:70
Mail::AddressList functionality should handle a really nasty obsolete address list
# No reason given
# ./spec/mail/elements/address_list_spec.rb:116
Mail::Address parsing email addresses from the wild should handle |jdoe@test . example|
# No reason given
# ./spec/mail/elements/address_spec.rb:537
mail encoding using default encoding quoting token unsafe chars should quote the display name
# No reason given
# ./spec/mail/encoding_spec.rb:98
Mail::Encodings decoding a string and detecting the encoding type should handle Base64 encoded ISO-2022-JP string
# No reason given
# ./spec/mail/encodings_spec.rb:436
Test emails from RFC2822 should handle the rfc obsolete addressing
# No reason given
# ./spec/mail/example_emails_spec.rb:205
Test emails from RFC2822 should handle the rfc obsolete dates
# No reason given
# ./spec/mail/example_emails_spec.rb:221
Test emails from RFC2822 should handle the rfc obsolete whitespace email
# No reason given
# ./spec/mail/example_emails_spec.rb:242

Failures:

1) Mail deliveries delivery_handler mail should not modify the Mail.deliveries object if using a delivery_handler
Failure/Error: doing { @message.deliver }.should_not change(Mail::TestMailer, :deliveries)
deliveries should not have changed, but did change from [#, , >, #, , >, #, , , >, , , , >, #, , >] to [#, , >, #, , >, #, , , >, , , , >, #, , >, #, , >]
# ./spec/mail/network_spec.rb:347:in `block (4 levels) in '

Finished in 20.89 seconds
1294 examples, 1 failure, 8 pending

Failed examples:

rspec ./spec/mail/network_spec.rb:345 # Mail deliveries delivery_handler mail should not modify the Mail.deliveries object if using a delivery_handler