private void assertReader(ChunkBuffer reader, Chunk... expected) { List<Chunk> res = Utils.list(reader); assertEquals(expected.length, res.size()); for (int i = 0; i < expected.length; i++) { assertEquals(expected[i], res.get(i)); } }
public synchronized Iterable<CRaSHPlugin<?>> getPlugins() { if (plugins == null) { List<CRaSHPlugin<?>> plugins = Utils.list(discovery.getPlugins()); for (CRaSHPlugin<?> plugin : plugins) { plugin.context = context; plugin.status = CRaSHPlugin.CONSTRUCTED; } this.plugins = plugins; } return plugins; }