ONJava.com -- The Independent Source for Enterprise Java
oreilly.comSafari Books Online.Conferences.

advertisement

AddThis Social Bookmark Button
Article:
  Twelve Best Practices For Spring XML Configurations
Subject:   Domain Objects in ApplicationContext
Date:   2006-02-16 09:40:13
From:   markchance1
Response to: Domain Objects in ApplicationContext

I have used this quite a bit in my latest project - but to create "mock" Domain objects for unit testing without the database. The benefit of this is having my collection of test data in one place so that the unit tests in all the various packages can easily access them. The alternative was creator/factory classes, but having them in Spring identified by name/id is pretty handy!