public void testCreateTypedEventChannel() throws Exception { IntHolder id = new IntHolder(); TypedEventChannel channel = typedChannelFactory_.create_typed_channel(new Property[0], new Property[0], id); assertEquals(typedChannelFactory_, channel.MyFactory()); }
public void testCreateChannel() throws Exception { final IntHolder channelID = new IntHolder(); final TypedEventChannel channel = factory_.create_typed_channel(new Property[0], new Property[0], channelID); assertNotNull(channel); final TypedEventChannel lookup = factory_.get_typed_event_channel(channelID.value); assertTrue(channel._is_equivalent(lookup)); int[] all_typed_channels = factory_.get_all_typed_channels(); assertTrue(Arrays.binarySearch(all_typed_channels, channelID.value) >= 0); }
protected void setUp() throws Exception { super.setUp(); Properties props = new Properties(); props.put(Attributes.ENABLE_TYPED_CHANNEL, "on"); servant_ = AbstractChannelFactory.newFactory(props); org.omg.CORBA.Object obj = servant_.activate(); typedChannelFactory_ = TypedEventChannelFactoryHelper.narrow(obj); objectUnderTest_ = typedChannelFactory_.create_typed_channel( new Property[0], new Property[0], new IntHolder()); }