On Dec 12, 12:27 pm, Phlip <[email protected]> wrote: > if you commented out this line (and any other line that squawks)... > > > @expected.parts << body_part # <=== ERROR HERE > > and printed out the mail's parts before asserting them... > > > mail = Notifier.create_notification() > > p mail.parts > > ...what would you see?
It looks like this... [#<TMail::Mail port=#<TMail::StringPort:id=0x2ea1e18> bodyport=#<TMail::StringPort:id=0x2ea1a12>>, #<TMail::Mail port=#<TMail::StringPort:id=0x2ea1486> bodyport=#<TMail::StringPort:id=0x2ea0f68>>] Something I have just discovered today. If you delay setting content_type to *after* adding the parts, it gets rid of that exception. Now it appears to be at least not causing an error, but I get a failure because (of course) the content types are subtly different. What's truly bizarre about it is that the MIME boundary string is quoted for the actual mail but not quoted for the expected mail, even though it doesn't need to be quoted in either case. TMail seems to be doing some weird things there. I think if I make the test environment overwrite TMail's new_boundary method, it might give me a way to dodge that. TX --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

