Re: Unit testing RMI Servers

Niclas Hedhman <[email protected]>
Newsgroups gmane.comp.java.sun.rmi
Message-ID <[email protected]>
On Monday 09 May 2005 14:55, David Whyte wrote:
> On 5/9/05, Niclas Hedhman <[email protected]> wrote:
> > On Monday 09 May 2005 14:26, David Whyte wrote:
> > > Can anyone advise of any previous work that may have been done to make
> > > this kind of test a little easier.  I don't mind doing it the long way
> > > I have outlined above, but if there is a neater way to go about it,
> > > bring it on ;)
> >
> > I think you should list what you want the test to capture.
> >
> > If you are talking unittesting only, I don't see the purpose to spawn a
> > separate thread at all (we must trust the Sun doesn't release JDKs with
> > severely faulty RMI implementations in them). If you want to make sure
> > that no local references are being handed around, then do separation
> > through classloader management instead.
>
> Its pretty much that I can see via the current JUnits that the
> functionality is working fine in the same local process, but I am
> skeptical that I have gotten it so that when it is deployed remotely,
> everything will be fine.  I do trust Sun's implementation, I promise

"same local process" == local references
  or
"same local process" == remote references
??

If you are using remote references in the tests today, you are going through
RMI, and it shouldn't work if you (for instance) forgotten to re-compile a
Stub after a Remote interface change.

I strongly suspect that you are actually talking more about function testing
or perhaps acceptance testing, than unit tests.


Cheers
Niclas

===========================================================================
To unsubscribe, send email to [email protected] and include in the body
of the message "signoff RMI-USERS".  For general help, send email to
[email protected] and include in the body of the message "help".

For a list of frequently asked RMI questions please refer to:
http://java.sun.com/j2se/1.3/docs/guide/rmi/faq.html

To view past RMI-USERS postings, please see:
http://archives.java.sun.com/archives/rmi-users.html
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.