}
private void doTest(Generator generator, Shape s, String... expected) {
Collection<RuleGraph> rules = s.getMatchPermutations(generator.getRuleGraph());
assertEquals(expected.length, rules.size());
int i=0;
for(Rule rule : CollectionUtils.collect(rules, new RuleGraphToRuleTransformer())){
assertEquals(expected[i++]+" @ 0, 0\n", rule.toString());
}
}