Class addConnectionListener_Test
- java.lang.Object
-
- javasoft.sqe.tests.jakarta.mail.util.MailTest
-
- javasoft.sqe.tests.jakarta.mail.event.ConnectionEvent.addConnectionListener_Test
-
- All Implemented Interfaces:
com.sun.javatest.Test
,jakarta.mail.event.ConnectionListener
,java.util.EventListener
public class addConnectionListener_Test extends MailTest implements jakarta.mail.event.ConnectionListener
This class tests the addConnectionListener() API. It does this by passing various valid input values and then checking the type/value of the returned object.Listen and notifies of open/close events to Folder/Store/Transport.
api2test: public addConnectionListener(ConnectionListener)
how2test: Call this API. Then verify that that the notification occur when changes occur to a folder/store/transport. If this happens then this test passed otherwise it fails.
-
-
Field Summary
-
Fields inherited from class javasoft.sqe.tests.jakarta.mail.util.MailTest
auth, debug, errors, from, host, iofile, log, mailbox, msgcount, newName, out, password, pattern, portnum, portvalue, properties, protocol, proxy, rootpath, session, status, subject, testbox, testname, to, tportnum, tportvalue, transport_host, transport_protocol, user, workdir
-
-
Constructor Summary
Constructors Constructor Description addConnectionListener_Test()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
closed(jakarta.mail.event.ConnectionEvent e)
void
disconnected(jakarta.mail.event.ConnectionEvent e)
void
dotest(jakarta.mail.Folder folder)
static void
main(java.lang.String[] argv)
void
opened(jakarta.mail.event.ConnectionEvent e)
com.sun.javatest.Status
run(java.lang.String[] argv, java.io.PrintWriter log, java.io.PrintWriter out)
Default run() method ; sets i/o streams.-
Methods inherited from class javasoft.sqe.tests.jakarta.mail.util.MailTest
checkMem, checkStatus, connect2host, createInputStream, createSession, ExceptionTest, getRootFolder, handlException, parseArgs, run
-
-
-
-
Method Detail
-
main
public static void main(java.lang.String[] argv)
-
opened
public void opened(jakarta.mail.event.ConnectionEvent e)
- Specified by:
opened
in interfacejakarta.mail.event.ConnectionListener
-
closed
public void closed(jakarta.mail.event.ConnectionEvent e)
- Specified by:
closed
in interfacejakarta.mail.event.ConnectionListener
-
disconnected
public void disconnected(jakarta.mail.event.ConnectionEvent e)
- Specified by:
disconnected
in interfacejakarta.mail.event.ConnectionListener
-
run
public com.sun.javatest.Status run(java.lang.String[] argv, java.io.PrintWriter log, java.io.PrintWriter out)
Description copied from class:MailTest
Default run() method ; sets i/o streams.
-
dotest
public void dotest(jakarta.mail.Folder folder) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-