I managed to make a similar workaround to enable reopening of session in unit
tests using your approach. I'm using wicket 6.7, hibernate 4 and spring
3.2.2.
please let me know if you have any problem in this configuration
Thanks a lot
Leon Nieuwoudt wrote
> Hi all,
>
> After about 5 minutes of "o
Just an update, the quick hack failed completely when testing on an XP
system, but it worked perfectly on Ubuntu.
Any links or example on getting Spring/Hibernate/WicketTester/JUnit4 to work
will be appreciated. "lmgtfy" will also suffice ;)
On Tue, Feb 16, 2010 at 9:57 AM, Leon Nieuwoudt wrote:
Hi Igor
Glad to hear there's another way.
I'm already using the Spring JUnit runner, like this:
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration
public class UserTest extends . {
@Test
public void testCRUD() {
// Code...
}
}
This what I tried:
* Adding @Tra
all you have to do is start a transaction before each unit test and
roll it back after. spring has base unit tests and test runners that
do this for you...
-igor
On Tue, Feb 16, 2010 at 12:13 AM, Leon Nieuwoudt
wrote:
> Yes this works when running the program in the Application Server
> environm
Yes this works when running the program in the Application Server
environment.
For JUnit testing (outside of the AS), I ran into this problem.
Is there maybe a better way to maybe wrap the OSIV Filter around Unit Tests?
On Tue, Feb 16, 2010 at 9:07 AM, Wilhelmsen Tor Iver wrote:
>
> I thought t
> After about 5 minutes of "omfg not that error again", I think I found a
> quick hack to avoid org.hibernate.LazyInitializationException with
> WicketTester. I've checked everywhere on the lists but didn't find a
> similar
> solution, so apologies if someone else already posted this. There may
> a
Hi all,
After about 5 minutes of "omfg not that error again", I think I found a
quick hack to avoid org.hibernate.LazyInitializationException with
WicketTester. I've checked everywhere on the lists but didn't find a similar
solution, so apologies if someone else already posted this. There may also