Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Declarative Services testing
Declarative Services testing [message #110133] Fri, 16 May 2008 06:20 Go to next message
Dmitry Hazin is currently offline Dmitry HazinFriend
Messages: 6
Registered: July 2009
Junior Member
Hi,

I'm trying to create the Unit Test for the Declarative Service. The
problem is that the service is not found:(
I tried to run tests from Eclipse (marking org.eclipse.equinox.ds in the
plugins list) and with ant build.
I tried to consume a service by creating ServiceTracker for it and
invoking waitForService() with some delay.
Also I tried to create unit test as a declarative service with the
configuration similar to this one:
<?xml version="1.0"?>
<component name="myTest">
<implementation
class="com.example.MyTest" />
<reference name="MyService"
interface="com.example.MyService"
bind="setMyService" unbind="unsetMyService" cardinality="1..1"
policy="dynamic" />
</component>
but without success.

It seems that ds bundle isn't started automatically when executing the
test. How can it be configured both for Eclipse and ant build?

Thanks,
Dmitry
Re: Declarative Services testing [message #110208 is a reply to message #110133] Sat, 17 May 2008 15:16 Go to previous message
Eclipse UserFriend
Originally posted by: zx.us.ibm.com

dhazin wrote:
> It seems that ds bundle isn't started automatically when executing the
> test. How can it be configured both for Eclipse and ant build?

Check out:

http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.ui.form s.examples/

Cheers,

~ Chris
Previous Topic:Organize Manifests
Next Topic:OSGI Tutorial - Getting Started with OSGi: Consuming a Service
Goto Forum:
  


Current Time: Sat Apr 27 02:45:33 GMT 2024

Powered by FUDForum. Page generated in 0.03344 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top