assertNotNull("Cons1 Service available", refcons1);
CheckService cs_cons1 = (CheckService) osgiHelper.getRawServiceObject(refcons1);
Properties props = cs_cons1.getProps();
Long id = (Long) props.get("id");
FooService fscons1 = (FooService) props.get("object");
assertEquals("id 1", 1, id.intValue());
checkCreatedObjects(prov2, 1);
// Step 2 : create a second consumer
cons3.start();
ServiceReference refcons2 = ipojoHelper.getServiceReferenceByName(CheckService.class.getName(), cons3.getInstanceName());
assertNotNull("Cons2 Service available", refcons2);
CheckService cs_cons2 = (CheckService) osgiHelper.getRawServiceObject(refcons2);
Properties props2 = cs_cons2.getProps();
Long id2 = (Long) props2.get("id");
FooService fscons2 = (FooService) props2.get("object");
assertEquals("id 2", 2, id2.intValue());
checkCreatedObjects(prov2, 2);
assertNotSame("Two objects", fscons1, fscons2);