use of com.hazelcast.core.ItemEvent in project camel by apache.
the class HazelcastListConsumerTest method add.
@Test
@SuppressWarnings("unchecked")
public void add() throws InterruptedException {
MockEndpoint out = getMockEndpoint("mock:added");
out.expectedMessageCount(1);
final ItemEvent<String> event = new ItemEvent<String>("mm", ItemEventType.ADDED, "foo", null);
argument.getValue().itemAdded(event);
assertMockEndpointsSatisfied(2000, TimeUnit.MILLISECONDS);
this.checkHeaders(out.getExchanges().get(0).getIn().getHeaders(), HazelcastConstants.ADDED);
}
use of com.hazelcast.core.ItemEvent in project camel by apache.
the class HazelcastListConsumerTest method remove.
@Test
@SuppressWarnings("unchecked")
public void remove() throws InterruptedException {
MockEndpoint out = getMockEndpoint("mock:removed");
out.expectedMessageCount(1);
final ItemEvent<String> event = new ItemEvent<String>("mm", ItemEventType.REMOVED, "foo", null);
argument.getValue().itemRemoved(event);
assertMockEndpointsSatisfied(2000, TimeUnit.MILLISECONDS);
this.checkHeaders(out.getExchanges().get(0).getIn().getHeaders(), HazelcastConstants.REMOVED);
}
use of com.hazelcast.core.ItemEvent in project camel by apache.
the class HazelcastSetConsumerTest method add.
@Test
@SuppressWarnings("unchecked")
public void add() throws InterruptedException {
MockEndpoint out = getMockEndpoint("mock:added");
out.expectedMessageCount(1);
final ItemEvent<String> event = new ItemEvent<String>("mm", ItemEventType.ADDED, "foo", null);
argument.getValue().itemAdded(event);
assertMockEndpointsSatisfied(2000, TimeUnit.MILLISECONDS);
this.checkHeaders(out.getExchanges().get(0).getIn().getHeaders(), HazelcastConstants.ADDED);
}
use of com.hazelcast.core.ItemEvent in project camel by apache.
the class HazelcastSetConsumerTest method remove.
@Test
@SuppressWarnings("unchecked")
public void remove() throws InterruptedException {
MockEndpoint out = getMockEndpoint("mock:removed");
out.expectedMessageCount(1);
final ItemEvent<String> event = new ItemEvent<String>("mm", ItemEventType.REMOVED, "foo", null);
argument.getValue().itemRemoved(event);
assertMockEndpointsSatisfied(2000, TimeUnit.MILLISECONDS);
this.checkHeaders(out.getExchanges().get(0).getIn().getHeaders(), HazelcastConstants.REMOVED);
}
use of com.hazelcast.core.ItemEvent in project camel by apache.
the class HazelcastQueueConsumerTest method remove.
@Test
@SuppressWarnings("unchecked")
public void remove() throws InterruptedException {
MockEndpoint out = getMockEndpoint("mock:removed");
out.expectedMessageCount(1);
final ItemEvent<String> event = new ItemEvent<String>("foo", ItemEventType.REMOVED, "foo", null);
argument.getValue().itemRemoved(event);
assertMockEndpointsSatisfied(2000, TimeUnit.MILLISECONDS);
this.checkHeaders(out.getExchanges().get(0).getIn().getHeaders(), HazelcastConstants.REMOVED);
}
Aggregations