Activity relies on many of the android APIs, including things like Resources
that are implemented in native code, so I don't think you are going to get
far trying to run it outside of the Android environment.

On Tue, Jan 13, 2009 at 4:37 AM, Koert <[email protected]> wrote:

>
> I have been developing an Android application and I keep wishing some
> king of dependency injection would be possible to make unit testing a
> bit easier. And I mean unit testing in the Eclipse IDE, not
> integration testing on the emulator or phone itself.
>
> I have been experimenting with reflection and I can make a simple kind
> of dependency injection working.
>
> It would be very nice if I could inject the dependencies into an
> Activity as it is created. I was looking at the instrumentation
> configuration in the manifest, thinking that I could configure some
> kind of interceptor that could enrich the Activity after creation and
> before it was started.
>
> See:
> http://code.google.com/android/reference/android/app/Instrumentation.html
>
> http://code.google.com/android/devel/bblocks-manifest.html
>
> However, I cannot figure out how to make it work; any suggestions how
> I might make it work?
>
> Thanks,
> Koert Zeilstra
>
> >
>


-- 
Dianne Hackborn
Android framework engineer
[email protected]

Note: please don't send private questions to me, as I don't have time to
provide private support.  All such questions should be posted on public
forums, where I and others can see and answer them.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to