james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Harmeet Bedi" <harm...@kodemuse.com>
Subject Re: Python for testing
Date Fri, 03 Jan 2003 10:02:31 GMT
----- Original Message -----
From: "Kenny Smith" <kenny@journalscape.com>
> I don't really have a specific area to focus on, but SMTP is at least a
> protocol I use, so I can get excited about it. :) I'm going to spend some
> time looking over the structure Harmeet already has (and I'm sure asking
him
> a bunch of questions) and I'll xref with the RFCs. :)

For pure protocol testing, one way is to this is to simulate a protocol
session.
Protocol Simulator simulates telnet protocol and verifies results using PERL
Regex. All of James' protocols build on telnet and can therefore be
simulated. It is capable of multithreaded test simulations.


take a look at
http://cvs.apache.org/viewcvs.cgi/jakarta-james/tests/src/conf/smtp.protocol
session?rev=1.1&content-type=text/vnd.viewcvs-markup

This protocol simulator runs this and similar scripts.
http://cvs.apache.org/viewcvs.cgi/jakarta-james/tests/src/java/org/apache/ja
mes/testing/ProtocolSimulator.java?rev=1.6&content-type=text/vnd.viewcvs-mar
kup

Darrel has a bunch similar protocol simulation test scripts under
http://cvs.apache.org/viewcvs.cgi/jakarta-james/proposals/imap2/test/org/apa
che/james/

Usage:
$ java org.apache.james.testing.ProtocolSimulator
        -s, --server
                Remote Server Host To Test Against
        -p, --port
                Remote Server Port To Test Against
        -t, --template
                Protocol Session Template
        -w, --workers
                Number Of Concurrent Simulations. Default Is 1.
        -i, --iterations
                Number Of Protocol Simulations Iterations Per Worker. Defaul
                t Is 1.
        -h, --help
                Usage Help

I was thinking of doing these improvements to the protocol simulator:
- Have a template mechanism that allows script inclusion and variables.
WebMacro/Velocity would do this well.
- Scripts would be templates and would generate output that would be
simulated by protocol simulator
Was also thinking of have
- Commands to retry/sleep. This would allow protocol simulation of say
remotemanager, pop3 and smtp interaction with sleep-retry.

Was hoping to have RFC testing as a subproject in James and potentially
interest other opensource projects to pool test effort. The main advantage
would be mulitple projects get tests baseline. James would have the
additional benefit that it knows when it has beat exim or sendmail or at
least where it stands relative to others. This maybe interesting to
commercial organizations too. Testing as a separate sub-project has been
deferred, but not rejected.

Harmeet


--
To unsubscribe, e-mail:   <mailto:james-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:james-dev-help@jakarta.apache.org>


Mime
View raw message