Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Testing email send and Test::MockObject

by pernod (Chaplain)
on Oct 08, 2004 at 07:57 UTC ( [id://397569]=note: print w/replies, xml ) Need Help??


in reply to Testing email send

Another alternative is using chromatic's Test::MockObject to simulate the mail server. Mocking allows you to unit test your mail generating component independently from the mail server, and you will be able to trap the output of your code to verify the contents of your mail.

This will not be enough, though, as you will need to test the component in combination with the mail server too. The unit tests will verify the interfaces between the two. I don't think mocking is the complete solution to your problem, but it will get you closer to your goal.

Good luck!

pernod
--
Mischief. Mayhem. Soap.

Update: Fixed som typos

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://397569]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2024-03-28 17:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found