//want it in chunks
@SuppressWarnings("unchecked")
@Test
public void testChunks() {
List l = new ArrayList();
l.add(new FactData("Q", "x", new ArrayList(), false));
l.add(new FactData("Q", "y", new ArrayList(), false));
l.add(new FactData("X", "a", new ArrayList(), false));
l.add(new FactData("X", "b", new ArrayList(), false));
l.add(new CallMethod("x","hello"));
l.add(new CallMethod("x","helloItherWay"));
l.add(new CallMethod("v","helloAgain"));
ExecutionTrace ex1 = new ExecutionTrace();
l.add(ex1);
l.add(new FactData("Z", "z", new ArrayList(), false));
l.add(new FactData("Q", "x", new ArrayList(), true));
l.add(new FactData("Q", "y", new ArrayList(), true));
l.add(new RetractFact("y"));
l.add(new CallMethod("x","hello"));
VerifyFact vf1 = new VerifyFact();
VerifyFact vf2 = new VerifyFact();
VerifyRuleFired vr1 = new VerifyRuleFired();
VerifyRuleFired vr2 = new VerifyRuleFired();
l.add(vf1);
l.add(vf2);
l.add(vr1);
l.add(vr2);
ExecutionTrace ex2 = new ExecutionTrace();
l.add(ex2);
VerifyFact vf3 = new VerifyFact();
l.add(vf3);
ScenarioHelper hlp = new ScenarioHelper();
List fx = hlp.lumpyMap(l);
assertEquals(9, fx.size());
Map first = (Map) fx.get(0);
assertEquals(2, first.size());
List fdl = (List) first.get("Q");
assertEquals(2, fdl.size());
FactData fd = (FactData) fdl.get(0);
assertEquals("x", fd.getName());
fd = (FactData) fdl.get(1);
assertEquals("y", fd.getName());
fdl = (List) first.get("X");
assertEquals(2, fdl.size());
fd = (FactData) fdl.get(0);
assertEquals("a", fd.getName());
CallFixtureMap callMap = (CallFixtureMap)fx.get(1);
assertEquals(2, callMap.size());
assertTrue(callMap.containsKey("x"));
FixtureList lcall1 = callMap.get("x");