QName serviceName = new QName("AccessAttachment");
RulesExchangeHandler handler = new RulesExchangeHandler(rci_model, serviceDomain, serviceName);
Service service = serviceDomain.registerService(serviceName, JavaService.fromClass(AccessAttachment.class), handler);
serviceDomain.registerServiceReference(service.getName(), service.getInterface(), service.getProviderHandler());
handler.start();
DataSource attachment = new TestDataSource("someAttach", "text/plain", "someAttachData");
new Invoker(serviceDomain, serviceName).operation("process").attachment(attachment.getName(), attachment).sendInOnly(holder);
handler.stop();
Assert.assertEquals("someAttachData", holder.getValue());
}