javamail-mock2 | JavaMail Mock2 - Open source mock classes | Mock library
kandi X-RAY | javamail-mock2 Summary
kandi X-RAY | javamail-mock2 Summary
open source mock classes for mockup javamail (useful especially for unittest). supports imap idle. e-mail hendrikdev22@gmail.com twitter @hendrikdev22. features * support imap, imaps, pop3, pop3s, smtp, smtps * support for smtp: mock transport.send() * supported for pop3: * cast to pop3folder * folder.getuid(message msg) * supported for imap: * cast to imapfolder * cast to uidfolder * idle * id * subfolders * folder.getmessagesbyuid(…) * delete/rename folders * append messages * unsupported for the moment: * all imap extensions except idle and id * casts to pop3message/imapmessage * store listeners. the library come in two flavors/modes * normal (or halfmock): allows also to connect to real imap/pop servers. use this if you have mixed testing setups (mockend an real server). require a little bit of setup. * fullmock: use this if you have mocked test only. normally no setup required. see unittests for how to use the library. maven site
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Get message inbox
- Returns all messages in inbox
- Returns a range of messages
- Deletes a folder
- Deletes this folder
- Renames a folder
- Renames this folder
- Create new mailbox
- Creates a new folder
- Copies the mime message to the given mailbox
- Add a mime message
- Closes this folder
- Tries to idle folder lock
- Get list of folders matching the pattern
- Connect to the mock mailbox
- Returns the number of deleted messages
- Gets a folder by name
- Sends message to given addresses
- Copy messages to a given folder
- Gets a list of folders matching the specified pattern
- Returns the list of folders subscribed to this mailbox
- Handle a mailbox change
- Retrieves the contents of this message
- Retrieve a range of messages
- Appends multiple Mime messages to the mailbox
- Add multiple messages to the mailbox
javamail-mock2 Key Features
javamail-mock2 Examples and Code Snippets
Community Discussions
Trending Discussions on javamail-mock2
QUESTION
I would like use javamail-mock2 in pax exam environment but the problem is that pax exam cannot see META-INF folder from test. How to add javamail.providers file to suite that javamail-mock2 will see configuration file and load mock providers?
MP
...ANSWER
Answered 2017-Jul-20 at 07:26The javamail-mock2 is maybe not compatible with OSGi. We have a mock-mail bundle we build and use for testing Camel in OSGi at: https://github.com/apache/camel/tree/master/tests/test-bundles/mock-javamail_1.7
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install javamail-mock2
You can use javamail-mock2 like any standard Java library. Please include the the jar files in your classpath. You can also use any IDE and you can run and debug the javamail-mock2 component as you would do with any other Java program. Best practice is to use a build tool that supports dependency management such as Maven or Gradle. For Maven installation, please refer maven.apache.org. For Gradle installation, please refer gradle.org .
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page