[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[List Home]
|
[eclipselink-users] Transactional Testing in Spring
|
- From: "Tim Hollosy" <hollosyt@xxxxxxxxx>
- Date: Tue, 14 Oct 2008 08:22:07 -0400
- Delivered-to: eclipselink-users@eclipse.org
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=NEsZqTmY9HG5CXO2kIZacme5llB4h7E3cEBeSDM8K4Q=; b=Q88D77z6XUdnox30TPjMTfl8UtTZyEtpcBRbQPItY1/2AwuyIfoqM8cFcjG0tLu/o4 e4zz9CnQGq68ums9Zalwod+Vp8KY8mIU/XHCpF9vwqip2DjFZ/2rgetrRVgMpCmF2Aha 3mNnuG4J6RPOhYl81f8uoU03a5zanawbHFLGY=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=m2M5SqyIcYtRP+k7VGQPetViv+eZNBZ7gTFwXe5P09YatANRkU5vATSbWU4jKyomno 1woiED7VD0avRA7myEJuUK3y/J9EyU7Jw8sGqacvO74YqF5jQ93jHdi+58Qyu9RXlScV ks+09LyapgLMcoL4O74LfedN68cEAeqxESTKE=
I'm having a problem doing some integration testing in spring with transactions.
I've got my test case that injects a DAO. I want to verify that a
unique constraint occurs on insert, well since eclipselink is smart
enough to not bother sending the SQL until a commit happens my SQL is
never executed.
How are people working around this? Are you somehow loading a
different persistence.xml that changes the caching behavior when
testing?
I would prefer to not have to do a commit and a delete to test an insert...
Ideas?
Thanks,
Tim