### Question:
ParamProvider implements AutoCloseable { public abstract Iterator<Object[]> iterator(); ParamProvider(ParamGenerator... paramGenerators); static Suggested suggested(Class<?>... parameterTypes); abstract Iterator<Object[]> iterator(); @SuppressWarnings("unchecked") void onResult(ExecutionResult result); @Override void close(); final ParamGenerator[] paramGenerators; }### Answer:
@Test public void testAllPermutationsSimple() { ParamProvider prov = new ParamProvider.AllPermutations( ParamGenerator.of(1, 2, 3), ParamGenerator.of(true, false) ); Iterator<Object[]> iter = prov.iterator(); List<List<Object>> all = new ArrayList<>(); while (iter.hasNext()) all.add(Arrays.asList(iter.next())); Assert.assertEquals( Arrays.asList( Arrays.asList(1, true), Arrays.asList(1, false), Arrays.asList(2, true), Arrays.asList(2, false), Arrays.asList(3, true), Arrays.asList(3, false) ), all ); }