### Question:
HBasePublisher extends BasePublisher implements IPublisher { @Override public void publish(Event event, Callback callback) { for (HBaseConfig config : configs) { if (!config.getFilters().stream().allMatch(filter -> filter.filter(event))) { continue; } switch (event.getEventType()) { case INSERT: hBaseClient.insert(config, event); break; case UPDATE: hBaseClient.update(config, event); break; case DELETE: hBaseClient.delete(config, event); break; default: break; } } } HBasePublisher(List<HBaseConfig> configs); @Override void publish(Event event, Callback callback); @Override void close();  }### Answer:
@Test public void test_publish() { HBaseConfig config = new HBaseConfig(); config.setFamily("tb1_family"); config.setQualifier("tb1_qualifier"); config.setPks(Collections.singletonList("id")); HBasePublisher publisher = new HBasePublisher(Collections.singletonList(config)); Callback callback = new EmptyCallback(); Event event = new Event(); publisher.publish(event, callback); }