AccumuloEventStorageBolt extends AccumuloBaseBolt { void populateMutation(Mutation mut, String columnFamily, ColumnVisibility vis, Map<String, String> fields) { for (Map.Entry<String, String> entry : fields.entrySet()) { String key = defaultString(entry.getKey()); String value = defaultString(entry.getValue()); mut.put(columnFamily, key, vis, new Value(value.getBytes())); } }  @Override void cleanup(); static final String EVENT_TABLE; static final String UUID_PREFIX; static final String UUID_PREFIX_DEFAULT; static final String VISIBILITY; static final String VISIBILITY_BY_FIELD; static final String SPLITS; static final int SPLITS_DEFAULT; }
@Test public void testPopulateMutation( @Injectable Mutation mut, @Injectable String columnFamily, @Injectable ColumnVisibility vis) throws Exception { Map<String, String> fields = new HashMap<>(); fields.put("key", "value"); new Expectations() {{ mut.put(columnFamily, "key", vis, (Value) any); }}; bolt.populateMutation(mut, columnFamily, vis, fields); }