ace-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Toni Menzel <t...@okidokiteam.com>
Subject Testing DependencyManager services
Date Mon, 07 Dec 2009 09:25:23 GMT
Hi,

maybe i am missing something, but how do i unit test Services that have
dependencies which are injected (usually) by the DependencyManager ?
Is there anything else than injecting those mocks via manual reflection ?

On the other hand, usually the approach is to support constructor injection
instead of field injection. Any thought in this direction at
DependencyManager ?
Even if not, i would propose giving those services a catch-all constructor
which can be used in out of container scenarios (testing).
(would be great if dependencymanager could live with that alone).

Toni

-- 
Toni Menzel
Independent Software Developer
Professional Profile: http://okidokiteam.com
toni@okidokiteam.com
http://www.ops4j.org     - New Energy for OSS Communities - Open
Participation Software.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message