tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Blevins <>
Subject Re: Problem with Testing OpenEJB Security - Examples
Date Wed, 16 Sep 2009 23:05:48 GMT

On Sep 12, 2009, at 3:35 AM, Quintin Beukes wrote:

> Is it possible to dynamic construct EJBs in the embedded container? If
> this is possible one could even go as far as making an
> openejb-junit.jar, which takes the form of:
> OpenEjbTest.runAs("admin", new Callable() {
> ...
> });
> Then the static method would have an EJB which it dynamically modifies
> to run as a given role.

No way to dynamically define ejbs at the moment.  For the use case  
above the InitialContext login approach might work better as it allows  
you to set the user/pass as a string.

On another note, I've also been kicking around the idea of creating a  
JUnit test runner which would open up some interesting possibilities  
such as annotating test methods with transaction and security  


View raw message