Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Adds receive functionality to the email testing application mockSMTP

branch: master

Fetching latest commit…


Cannot retrieve the latest commit at this time

Octocat-spinner-32 app
Octocat-spinner-32 autotest
Octocat-spinner-32 lib
Octocat-spinner-32 spec
Octocat-spinner-32 .DS_Store
Octocat-spinner-32 MIT-LICENSE
Octocat-spinner-32 README
Octocat-spinner-32 Rakefile
Octocat-spinner-32 init.rb
Octocat-spinner-32 mailfactory.tmproj
## mockIMAP

mockIMAP is a plugin that compliments MockSMTP allows you to send and view emails in a test environment without a connection to the internet. If you are utilizing mockSMTP then the mockIMAP is a plugin that will allow you to test your receive method by downloading the last message sent to the test SMTP server. 

## install

script/plugin install git://

requires sqlite3

sudo gem install sqlite3-ruby

## Parameters

:location => (location to the file in mockSMTP) 

Note, :location is optional and will default to /Users/yourusername/Documents/MockSMTP/ You can find this path by opening preferences in MockSMTP.

## Examples

# get array of all emails
>> emails = getMockEmails
=> [email(0)]

# get last email sent
>> lastEmail = getMockEmails.last
=> email(last)

# specify location of the mockSMTP data file - (only needed if you move the data file)
>> emails = getMockEmails(:location => '/Users/richardschneeman/Documents/MockSMTP/'
=>  [email(0)]

## About

I created this to help test out my rails application WhySpam.Me allows you to generate a  [free disposable email]( that you can give to websites. If they start to send you spam, you can destroy the disposable email and submit a survey letting the world know who sells your information.  If you want to fight back against spam, or just want to check out my site i would appreciate the visit. WhySpam is a creative commons licensed open source project, help out at:

I am not affiliated with mockSMTP

Copyright (c) 2009 [Richard Schneeman || ], released under the MIT license 

## Issues

1. Will not download attachments (i think, haven't tested this)
2. Need feedback for additional use cases, I only ever need the last email sent, but maybe a lookup based on to_email, etc. Let me know how you would envision this plugin working. 
Something went wrong with that request. Please try again.