directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Enrique Rodriguez" <>
Subject Re: Issues with tests
Date Sun, 07 Oct 2007 01:26:43 GMT
On 10/5/07, Alex Karasulu <> wrote:
> There were a slew of copy and paste problems that I had to fix all the tests
> created recently:
> ...

Thanks for doing this.  The clean-up has been much needed.

> ...
> Furthermore they don't seem to follow the pattern of using the
> AbstractTestCase and AbstractServerTestCase
> classes.  It would help a lot if you tried to use these instead of
> duplicating the setUp() code.   Eventually
> switching to the FastXXXITest that Emmanuel setup should be the best.
> ...

IIRC, the base classes you mention cannot currently be reused for the
non-LDAP protocol providers.  The setUp() method in question does not
allow modification to the configuration prior to the startup of the
server.  Once the server is started up, there is no way to dynamically
reconfigure.  Thus the "cut & paste" code you see is simply the
minimum boilerplate for starting a server instance when custom config
is required.

The non-LDAP protocol providers must make changes to the:
1)  enabled protocols (all PP besides LDAP are disabled by default)
2)  enabled schema (eg Kerberos)
3)  enabled interceptors (eg key derivation interceptor)
4)  advanced tests (multi-realm) may require additional partitions.

In short, the test base classes are highly LDAP-centric.  This
includes the SASL GSSAPI test, which uses Kerberos.

Perhaps as the tests are migrated to the FastXXXITest test we can
figure out to allow subclasses to make these changes in a clean
manner.  Could be as simple as some template methods called by the
setUp() method.


View raw message