Search in sources :

Example 1 with SimpleClass

use of org.apache.felix.ipojo.runtime.core.components.SimpleClass in project felix by apache.

the class TestSimplePS method testWhenNoInterface.

@Test
public void testWhenNoInterface() {
    String factoryName = "org.apache.felix.ipojo.runtime.core.components.SimpleClass";
    ComponentInstance ci = ipojoHelper.createComponentInstance(factoryName);
    osgiHelper.waitForService(SimpleClass.class.getName(), null, 5000);
    SimpleClass simple = (SimpleClass) osgiHelper.getServiceObject(SimpleClass.class.getName(), null);
    assertEquals("Hello", simple.hello());
    ci.dispose();
}
Also used : ComponentInstance(org.apache.felix.ipojo.ComponentInstance) SimpleClass(org.apache.felix.ipojo.runtime.core.components.SimpleClass) Test(org.junit.Test)

Aggregations

ComponentInstance (org.apache.felix.ipojo.ComponentInstance)1 SimpleClass (org.apache.felix.ipojo.runtime.core.components.SimpleClass)1 Test (org.junit.Test)1